diff options
-rw-r--r-- | pym/portage/versions.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/pym/portage/versions.py b/pym/portage/versions.py index b51b53ae5..d4699d1ab 100644 --- a/pym/portage/versions.py +++ b/pym/portage/versions.py @@ -306,10 +306,10 @@ def catsplit(mydep): def best(mymatches): """Accepts None arguments; assumes matches are valid.""" - if mymatches is None: - return "" - if not len(mymatches): + if not mymatches: return "" + if len(mymatches) == 1: + return mymatches[0] bestmatch = mymatches[0] p2 = catpkgsplit(bestmatch)[1:] for x in mymatches[1:]: |