Merge pull request #285 from Gluejar/fix_no_authors

authors should always return a query set
pull/1/head
Raymond Yee 2014-01-23 20:09:24 -08:00
commit 3906bc0a7b
1 changed files with 1 additions and 1 deletions

View File

@ -1079,7 +1079,7 @@ class Work(models.Model):
for edition in self.editions.all():
if edition.authors.all().count()>0:
return edition.authors.all()
return []
return Author.objects.none()
def author(self):
# assumes that they come out in the same order they go in!