1
0
Fork 0

Merge pull request #1062 from alisww/storygraph-import

add storygraph import
This commit is contained in:
Mouse Reeve 2021-05-10 16:23:00 -07:00 committed by GitHub
commit 27fe09a32b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 49 additions and 2 deletions

View file

@ -128,7 +128,9 @@ class ImportItem(models.Model):
@property
def rating(self):
"""x/5 star rating for a book"""
return int(self.data["My Rating"])
if self.data.get("My Rating", None):
return int(self.data["My Rating"])
return None
@property
def date_added(self):