From f06b9b5ec232ab813a953537c29f352dd332cd30 Mon Sep 17 00:00:00 2001 From: randogoth Date: Mon, 22 May 2023 11:47:33 +0300 Subject: [PATCH] debug --- userdb/db.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/userdb/db.py b/userdb/db.py index 413e159..37353e2 100644 --- a/userdb/db.py +++ b/userdb/db.py @@ -17,7 +17,7 @@ app = Flask(__name__) @app.route("/track", methods = ['GET']) def track(): - if request.method == 'GET' and request.args.get('hash'): + if request.method == 'GET' and request.args.get('hash') and request.args.get('cat'): hash = str(request.args.get('hash')) cat = str(request.args.get('cat')) @@ -30,7 +30,7 @@ def track(): else: db = {} if hash in db.keys(): - visits = db[hash]['visits'] + visits = db[hash][cat] else: visits = list()