From 6ce234c5446d5465d60ee7fbc14b0eedc6013c69 Mon Sep 17 00:00:00 2001 From: Raffaele Salmaso Date: Sun, 18 Feb 2018 15:30:43 +0100 Subject: [PATCH] Use MIDDLEWARE instead of MIDDLEWARE_CLASSES --- testproject/testproject/settings/base.py | 2 +- testproject/testproject/settings/dev.py | 2 +- tests/settings.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/testproject/testproject/settings/base.py b/testproject/testproject/settings/base.py index f6cfc908..2acacfb1 100644 --- a/testproject/testproject/settings/base.py +++ b/testproject/testproject/settings/base.py @@ -55,7 +55,7 @@ INSTALLED_APPS = [ TEST_RUNNER = 'django.test.runner.DiscoverRunner' -MIDDLEWARE_CLASSES = [ +MIDDLEWARE = [ 'django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.common.CommonMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', diff --git a/testproject/testproject/settings/dev.py b/testproject/testproject/settings/dev.py index 43168039..78a62a74 100644 --- a/testproject/testproject/settings/dev.py +++ b/testproject/testproject/settings/dev.py @@ -12,7 +12,7 @@ EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend' try: import debug_toolbar # @UnusedImport - MIDDLEWARE_CLASSES = list(MIDDLEWARE_CLASSES) + [ + MIDDLEWARE = list(MIDDLEWARE) + [ 'debug_toolbar.middleware.DebugToolbarMiddleware', ] INSTALLED_APPS = list(INSTALLED_APPS) + ['debug_toolbar'] diff --git a/tests/settings.py b/tests/settings.py index bf3ad321..f573ae22 100644 --- a/tests/settings.py +++ b/tests/settings.py @@ -37,7 +37,7 @@ INSTALLED_APPS = [ 'wiki.plugins.macros.apps.MacrosConfig', 'wiki.plugins.globalhistory.apps.GlobalHistoryConfig', ] -MIDDLEWARE_CLASSES = [ +MIDDLEWARE = [ 'django.middleware.common.CommonMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', -- 2.45.2