Fix bad variable name

This commit is contained in:
Joshua Boniface 2019-07-08 22:24:18 -04:00
parent 7889bd88e3
commit b0bdf72310
1 changed files with 1 additions and 1 deletions

View File

@ -83,7 +83,7 @@ def authenticator(function):
return function(*args, **kwargs)
# Direct token-based authentication
if 'token' in flask.request.values:
if any(found_token for token in config['auth_tokens'] if flask.request.values['token'] == token['token']):
if any(token for token in config['auth_tokens'] if flask.request.values['token'] == token['token']):
return function(*args, **kwargs)
else:
return flask.jsonify({"message":"Authentication failed"}), 401