fix: exception on broken captures in stats

pull/528/head
Raphaël Vinot 2022-09-28 02:10:55 +02:00
parent 0074f33544
commit dcc6b158b0
1 changed files with 2 additions and 0 deletions

View File

@ -1084,6 +1084,8 @@ class Lookyloo():
self.logger.warning(f'Unable load cache for {cache.get("uuid")} - {e}.')
for cache in self.sorted_capture_cache() + archived:
if not hasattr(cache, 'timestamp'):
continue
date_submission: datetime = cache.timestamp
if date_submission.year not in stats: