aboutsummaryrefslogtreecommitdiff
path: root/app/auth.py
diff options
context:
space:
mode:
Diffstat (limited to 'app/auth.py')
-rw-r--r--app/auth.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/auth.py b/app/auth.py
index c9fe89b..aa278f2 100644
--- a/app/auth.py
+++ b/app/auth.py
@@ -10,7 +10,7 @@ auth = HTTPTokenAuth(scheme='Bearer')
def verify_token(token):
try:
with engine.begin() as conn:
- token = conn.execute(sqlalchemy.text('SELECT * FROM accounts WHERE account_name = :account_name'), [{'account_name': token}]).fetchone()
+ token = conn.execute(sqlalchemy.text('SELECT * FROM accounts WHERE api_key = :api_key'), [{'api_key': token}]).fetchone()
return token[0]
except TypeError:
return False \ No newline at end of file