diff options
author | Matthew Lemon <lemon@matthewlemon.com> | 2020-10-17 14:46:23 +0100 |
---|---|---|
committer | Matthew Lemon <lemon@matthewlemon.com> | 2020-10-17 14:46:23 +0100 |
commit | c1a64fc08f7e21c5c0933f09c665ff5a25dd8868 (patch) | |
tree | c729e128233070125280dcf550f86dbc59d06088 /config/settings | |
parent | 59592232da815f4e8c6f61cb9042e738990c1b6e (diff) |
replaced all LoginRequiredMixin and decorators with custom middleware
Diffstat (limited to 'config/settings')
-rw-r--r-- | config/settings/gcloud_settings.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/config/settings/gcloud_settings.py b/config/settings/gcloud_settings.py index 3a8912f..a057db8 100644 --- a/config/settings/gcloud_settings.py +++ b/config/settings/gcloud_settings.py @@ -169,12 +169,17 @@ MIDDLEWARE = [ 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware', 'django.middleware.clickjacking.XFrameOptionsMiddleware', + 'config.middleware.LoginRequiredMiddleware' ] ROOT_URLCONF = 'config.urls' WSGI_APPLICATION = 'config.wsgi.application' +LOGIN_EXEMPT_URLS = ( + r"account/login", + r"account/logout" +) # Database # https://docs.djangoproject.com/en/2.1/ref/settings/#databases |