Optimize templates & clean code

This commit is contained in:
Nyymix 2025-04-26 20:39:57 +03:00
parent 0c1c888547
commit 86d9ca5066
11 changed files with 98 additions and 48 deletions

View file

@ -13,9 +13,8 @@ def site_config(request):
try:
with open(config_path, 'r') as f:
config = json.load(f)
cache.set('site_config', config, 3600)
cache.set('site_config', config, 3600)
except FileNotFoundError:
config = {}
return {'site_config': config}