diff --git a/files/__main__.py b/files/__main__.py index e58ed4284..301b743c0 100644 --- a/files/__main__.py +++ b/files/__main__.py @@ -109,6 +109,8 @@ def after_request(response): response.headers.add("X-Frame-Options", "deny") return response -with open("marsey_count.json", 'r') as f: cache.set("marsey_count", loads(f.read())) +if cache.get("marsey_count") == None: + with open("marsey_count.json", 'r') as f: + cache.set("marsey_count", loads(f.read())) from files.routes import * \ No newline at end of file