Cleanup in packaging: don’t unnecessarily instantiate exceptions

This commit is contained in:
Éric Araujo 2011-06-04 22:33:16 +02:00
parent 35a4d01a92
commit 2ef747cb77
4 changed files with 4 additions and 4 deletions

View file

@ -135,7 +135,7 @@ class ReleaseInfo(IndexReference):
not return one existing distribution.
"""
if len(self.dists) == 0:
raise LookupError()
raise LookupError
if dist_type:
return self[dist_type]
if prefer_source: