|
@@ -63,10 +63,9 @@ if __name__ == '__main__':
|
|
|
temp_status_json, _ = model.get_json_file(player_id)
|
|
temp_status_json, _ = model.get_json_file(player_id)
|
|
|
print(f'{minutes_to_go}: temp_status_json: ')
|
|
print(f'{minutes_to_go}: temp_status_json: ')
|
|
|
pprint(temp_status_json)
|
|
pprint(temp_status_json)
|
|
|
- if 'alert' in temp_status_json:
|
|
|
|
|
- alerts = temp_status_json['alert']
|
|
|
|
|
- else:
|
|
|
|
|
|
|
+ if 'alert' not in temp_status_json:
|
|
|
temp_status_json['alert'] = {'15': False, '10': False, '5': False, '1': False}
|
|
temp_status_json['alert'] = {'15': False, '10': False, '5': False, '1': False}
|
|
|
|
|
+ alerts = temp_status_json['alert']
|
|
|
if not alerts[str(minutes_to_go)]:
|
|
if not alerts[str(minutes_to_go)]:
|
|
|
# We have not sent this alert before
|
|
# We have not sent this alert before
|
|
|
name_alert = status['name']
|
|
name_alert = status['name']
|