forked from enviPath/enviPy
[Feature] Move Login exempt urls to settings (#86)
Co-authored-by: Tim Lorsbach <tim@lorsba.ch> Reviewed-on: enviPath/enviPy#86
This commit is contained in:
@ -341,3 +341,9 @@ FLAGS = {
|
||||
'ENVIFORMER': ENVIFORMER_PRESENT,
|
||||
'APPLICABILITY_DOMAIN': APPLICABILITY_DOMAIN_ENABLED,
|
||||
}
|
||||
|
||||
LOGIN_EXEMPT_URLS = [
|
||||
'/api/legacy/',
|
||||
'/o/token/',
|
||||
'/o/userinfo/',
|
||||
]
|
||||
|
||||
@ -11,7 +11,6 @@ class LoginRequiredMiddleware:
|
||||
reverse('logout'),
|
||||
reverse('admin:login'),
|
||||
reverse('admin:index'),
|
||||
'/api/legacy/'
|
||||
] + getattr(settings, 'LOGIN_EXEMPT_URLS', [])
|
||||
|
||||
def __call__(self, request):
|
||||
|
||||
Reference in New Issue
Block a user