Commit cbc05156 authored by okhin's avatar okhin 🚴

Fixing #6 - splitting fetchone on a different line

parent 22f07402
......@@ -464,7 +464,8 @@ def static_files(filepath):
return static_file(filepath, root='./views')
def login_admin(user, password):
user = db.execute('SELECT api, token, admin FROM users where api = ?', user).fetchone()
user = db.execute('SELECT api, token, admin FROM users where api = ?', user)
user = user.fetchone()
if user is None:
# user does not exist
return False
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment