From 11cc94d59c46eb32b847dc2e67eea3c0c877a289 Mon Sep 17 00:00:00 2001 From: Aroy-Art Date: Tue, 14 May 2024 21:05:05 +0200 Subject: [PATCH] Add: debug context processor --- archivist/apps/context_processors.py | 4 ++++ archivist/core/settings.py | 1 + 2 files changed, 5 insertions(+) create mode 100644 archivist/apps/context_processors.py diff --git a/archivist/apps/context_processors.py b/archivist/apps/context_processors.py new file mode 100644 index 0000000..4d7a447 --- /dev/null +++ b/archivist/apps/context_processors.py @@ -0,0 +1,4 @@ +from django.conf import settings + +def debug(context): + return {'DEBUG': settings.DEBUG} diff --git a/archivist/core/settings.py b/archivist/core/settings.py index ea6f45a..f222e7f 100644 --- a/archivist/core/settings.py +++ b/archivist/core/settings.py @@ -94,6 +94,7 @@ TEMPLATES = [ 'django.template.context_processors.request', 'django.contrib.auth.context_processors.auth', 'django.contrib.messages.context_processors.messages', + 'apps.context_processors.debug', ], }, },