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 91b8cc164..cf8d20d4f 100644 --- a/pym/portage_versions.py +++ b/pym/portage_versions.py @@ -311,10 +311,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:]: |