lines added to be compliant with standards
This commit is contained in:
parent
1a44c6b9d0
commit
d6d9c39922
@ -25,8 +25,10 @@ Simple decorator container for general purpose
|
|||||||
from django.shortcuts import redirect
|
from django.shortcuts import redirect
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
|
|
||||||
LOG = logging.getLogger('django_openstack.syspanel')
|
LOG = logging.getLogger('django_openstack.syspanel')
|
||||||
|
|
||||||
|
|
||||||
def enforce_admin_access(fn):
|
def enforce_admin_access(fn):
|
||||||
""" Preserve unauthorized bypass typing directly the URL and redirects to
|
""" Preserve unauthorized bypass typing directly the URL and redirects to
|
||||||
the overview dash page """
|
the overview dash page """
|
||||||
@ -37,4 +39,4 @@ def enforce_admin_access(fn):
|
|||||||
LOG.warn('Redirecting user "%s" from syspanel to dash ( %s )' %
|
LOG.warn('Redirecting user "%s" from syspanel to dash ( %s )' %
|
||||||
( args[0].user.username, fn.__name__) , exc_info=True)
|
( args[0].user.username, fn.__name__) , exc_info=True)
|
||||||
return redirect('dash_overview')
|
return redirect('dash_overview')
|
||||||
return dec
|
return dec
|
||||||
|
Loading…
x
Reference in New Issue
Block a user