database caller crash fix

This commit is contained in:
Neythen Treloar 2022-03-04 16:32:41 +00:00
parent 9fa50f1d8a
commit 874f88fdd3

View File

@ -723,7 +723,7 @@ if __name__ == '__main__':
# update if last update was before the previous days closing
forex_time = datetime.strptime(last_updates['forex'], "%d/%m/%Y %H:%M:%S")
CET_time = datetime.now(CET_zone)
CET_time = datetime.now(CET_zone).replace(tzinfo=None)
yday_update = (CET_time.replace(hour=17, minute=00, second=0, microsecond=0) - dt.timedelta(days=1)).replace(tzinfo=None)
diff = (CET_time.replace(tzinfo=None) - forex_time).total_seconds()/60