fixed indent spacing issues

This commit is contained in:
Justin 2023-06-14 18:03:19 +08:00 committed by GitHub
parent 528fc81c01
commit 0d464c965f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -271,7 +271,7 @@ def index():
economic_settings = json.load(f)
f.close()
except:
economic_settings = {"feature": "Economic Calendar", "speed": "medium", "speed2": "medium", "animation": "up", "importance": "Med - High", "title": True, "timezone": "US/Eastern", "countries": ["United States"], "events": []}
economic_settings = {"feature": "Economic Calendar", "speed": "medium", "speed2": "medium", "animation": "up", "importance": "Med - High", "title": True, "timezone": "US/Eastern", "countries": ["United States"], "events": []}
try:
f = open('csv/scheduler.json','r')
@ -1245,7 +1245,7 @@ def save_economic_settings(input_settings):
current_settings = json.load(f)
f.close()
except:
current_settings = {"feature": "Economic Calendar", "speed": "medium", "speed2": "medium", "animation": "up", "importance": "Med - High", "title": True, "timezone": "US/Eastern", "countries": ["United States"], "events": []}
current_settings = {"feature": "Economic Calendar", "speed": "medium", "speed2": "medium", "animation": "up", "importance": "Med - High", "title": True, "timezone": "US/Eastern", "countries": ["United States"], "events": []}
current_settings['speed'] = input_settings['speed'].lower()
current_settings['speed2'] = input_settings['speed2'].lower()
@ -1260,8 +1260,8 @@ def save_economic_settings(input_settings):
json.dump(current_settings, f)
f.close()
except:
with open('csv/economic_settings.json', 'w') as f:
json.dump(all_economic_settings, f)
with open('csv/economic_settings.json', 'w') as f:
json.dump(all_economic_settings, f)
f = open('csv/last_updates.json', 'r')
last_updates = json.load(f)