Changed Author reporting to favor Null entries

This commit is contained in:
Mike
2019-10-06 16:42:37 -04:00
parent 7dd0fe00e0
commit 770ad9ff95

View File

@@ -94,8 +94,7 @@ class Catalogue:
title = book['path'].split('/')[-1].rsplit('.', 1)[0]
else: title = title.contents[0]
author = soup.find("dc:creator")
if author == None: author = 'Unlisted'
else: author = author.contents[0]
if author != None: author = author.contents[0]
try: cover = self.extract_cover_image(book_zip, book)
except IndexError:
# cover = self.extract_cover_html(book_zip, book)