1

Inject settings into template context

This commit is contained in:
Jake Howard 2020-04-13 10:42:21 +01:00
parent d5c04c7dee
commit a0cddae1c7
Signed by: jake
GPG Key ID: 57AFB45680EDD477
2 changed files with 6 additions and 0 deletions

View File

@ -0,0 +1,5 @@
from django.conf import settings
def settings_injector(request=None):
return {"settings": settings}

View File

@ -61,6 +61,7 @@ TEMPLATES = [
"context_processors": [
"django.template.context_processors.debug",
"django.template.context_processors.request",
"website.common.context_processors.settings_injector",
],
},
},