Do not allow data to be used before it has a value

master
Simon Quigley 2 weeks ago
parent 641d46f8d2
commit ea51a90321

@ -191,6 +191,7 @@ class EmailPolicy(BasePolicy, Rest):
except URLError as e: except URLError as e:
self.logger.error("Error getting uploader from Launchpad for %s/%s: %s", self.logger.error("Error getting uploader from Launchpad for %s/%s: %s",
pkg, version, e.reason) pkg, version, e.reason)
return []
try: try:
source = next(reversed(data["entries"])) source = next(reversed(data["entries"]))
# IndexError means no packages in -proposed matched this name/version, # IndexError means no packages in -proposed matched this name/version,

Loading…
Cancel
Save