make chat count 0 in localhost

master
Aevann1 2022-08-22 23:02:20 +02:00
parent be251e7756
commit 4a111df278
2 changed files with 2 additions and 1 deletions

View File

@ -125,6 +125,8 @@ def teardown_request(error):
del g.db
stdout.flush()
cache.set(f'{app.config["SERVER_NAME"]}_online', 0, timeout=0)
if app.config["SERVER_NAME"] == 'localhost':
from files.routes import *
# from files.routes.chat import *

View File

@ -18,7 +18,6 @@ else:
typing = []
online = []
cache.set(ONLINE_STR, len(online), timeout=0)
muted = cache.get(f'{SITE}_muted') or {}
messages = cache.get(f'{SITE}_chat') or []
total = cache.get(f'{SITE}_total') or 0