Make progress work with block count

Break database thoroughly
Fix pdf year bug
This commit is contained in:
BasioMeusPuga
2018-03-31 03:03:49 +05:30
parent 0b8427c864
commit aff69d95c1
8 changed files with 151 additions and 141 deletions

View File

@@ -63,8 +63,8 @@ class ParsePDF:
def get_year(self):
try:
year = self.metadata.find('MetadataDate').text
return year.replace('\n', '')
except AttributeError:
return int(year.replace('\n', '')[:4])
except (AttributeError, ValueError):
return 9999
def get_cover_image(self):