8
0
Fork 0
mirror of https://gitlab2.federez.net/re2o/re2o synced 2024-09-12 01:03:09 +00:00

fix: 🐛 Quick fix bug with MIDDLEWARE_CLASSES

Support for django 2.22 introduces the use of MIDDLEWARE instead of MIDDLEWARE_CLASSES. This change was not reflected everywhere, about function for instance.
This commit is contained in:
Yoann Pétri 2021-02-18 16:10:53 +01:00 committed by klafyvel
parent 848b5bb7a1
commit f95babce51
2 changed files with 3 additions and 3 deletions

View file

@ -111,9 +111,9 @@ AUTHENTICATION_BACKENDS = ["re2o.login.RecryptBackend"]
# Include debug_toolbar middleware if activated
if "debug_toolbar" in INSTALLED_APPS:
# Include this middleware at the beggining
MIDDLEWARE_CLASSES = (
MIDDLEWARE = (
"debug_toolbar.middleware.DebugToolbarMiddleware",
) + MIDDLEWARE_CLASSES
) + MIDDLEWARE
# Change the default show_toolbar middleware
DEBUG_TOOLBAR_CONFIG = {
"SHOW_TOOLBAR_CALLBACK": "re2o.middleware.show_debug_toolbar"

View file

@ -109,7 +109,7 @@ def about_page(request):
git_info_commit = NO_GIT_MSG
git_info_commit_date = NO_GIT_MSG
dependencies = settings.INSTALLED_APPS + settings.MIDDLEWARE_CLASSES
dependencies = settings.INSTALLED_APPS + settings.MIDDLEWARE
try:
president = Mandate.get_mandate().president.get_full_name()