Use updated date if available

main
Bob Mottram 2023-12-30 13:06:24 +00:00
parent 9ff0b226f0
commit 6c56b786eb
1 changed files with 2 additions and 0 deletions

View File

@ -200,6 +200,8 @@ def _add_book_to_reader(reader_books_json: {}, book_dict: {}) -> None:
if 'timeline' not in reader_books_json: if 'timeline' not in reader_books_json:
reader_books_json['timeline'] = {} reader_books_json['timeline'] = {}
published = book_dict['published'] published = book_dict['published']
if book_dict.get('updated'):
published = book_dict['updated']
post_time_object = \ post_time_object = \
date_from_string_format(published, ["%Y-%m-%dT%H:%M:%S%z"]) date_from_string_format(published, ["%Y-%m-%dT%H:%M:%S%z"])
if post_time_object: if post_time_object: