Fix page numbers

This commit is contained in:
Yohann D'ANELLO 2020-02-10 16:32:13 +01:00
parent 939efe01a0
commit e4d1ed852f
1 changed files with 2 additions and 0 deletions

View File

@ -86,6 +86,8 @@ class BedetequeScraper:
search_nb_pages = re.search(regex_nb_of_pages, content)
if search_nb_pages and search_nb_pages.group(1).isnumeric():
data['number_of_pages'] = search_nb_pages.group(1)
elif 'number_of_pages' not in data:
data['number_of_pages'] = 0
# Get author and illustrator
author = re.search(regex_author, content)