we should check for request.user['status'] not request.user['session'], clearly.
This commit is contained in:
parent
74ae6b112a
commit
e745ce10c9
@ -33,7 +33,7 @@ def require_active_login(controller):
|
|||||||
Require an active login from the user.
|
Require an active login from the user.
|
||||||
"""
|
"""
|
||||||
def new_controller_func(request, *args, **kwargs):
|
def new_controller_func(request, *args, **kwargs):
|
||||||
if not request.user or not request.user.get('session') == 'active':
|
if not request.user or not request.user.get('status') == u'active':
|
||||||
# TODO: Indicate to the user that they were redirected
|
# TODO: Indicate to the user that they were redirected
|
||||||
# here because an *active* user is required.
|
# here because an *active* user is required.
|
||||||
return exc.HTTPFound(
|
return exc.HTTPFound(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user