Bugfix: crash on "key not found" error

This commit is contained in:
Bo Maryniuk 2016-01-22 18:39:30 +01:00
parent ea75f55a1a
commit 514f6349d4

View File

@ -1437,8 +1437,8 @@ def latest(
targets[pkg] = avail[pkg]
else:
for pkg in desired_pkgs:
if not avail[pkg]:
if not cur[pkg]:
if pkg not in avail:
if not cur.get(pkg):
msg = 'No information found for \'{0}\'.'.format(pkg)
log.error(msg)
problems.append(msg)