parent
35437c9f55
commit
4a4eee5e05
10 changed files with 199 additions and 35 deletions
|
@ -3,7 +3,7 @@
|
|||
import features
|
||||
from flask import abort
|
||||
from auth.auth_context import (get_validated_oauth_token, get_authenticated_user,
|
||||
get_validated_token, get_grant_user_context)
|
||||
get_validated_token, get_grant_context)
|
||||
from functools import wraps
|
||||
|
||||
|
||||
|
@ -29,7 +29,7 @@ def check_anon_protection(func):
|
|||
|
||||
# Check for validated context. If none exists, fail with a 401.
|
||||
if (get_authenticated_user() or get_validated_oauth_token() or get_validated_token() or
|
||||
get_grant_user_context()):
|
||||
get_grant_context()):
|
||||
return func(*args, **kwargs)
|
||||
|
||||
abort(401)
|
||||
|
|
Reference in a new issue