mirror of
https://expo.survex.com/repositories/troggle/.git
synced 2026-02-08 08:38:35 +00:00
tidy trailing slash everywhere & fix tests
This commit is contained in:
@@ -113,7 +113,7 @@ FORM_RENDERER = "django.forms.renderers.TemplatesSetting" # Required to customi
|
||||
# see https://docs.djangoproject.com/en/dev/topics/http/middleware/#upgrading-pre-django-1-10-style-middleware
|
||||
# Seriously, read this: https://www.webforefront.com/django/middlewaredjango.html which is MUCH BETTER than the docs
|
||||
|
||||
# We are NOT using the home-built SmartAppendSlashMiddleware
|
||||
# We are NOT using the home-built TroggleAppendSlashMiddleware, NOR are we using the Django system append_slash
|
||||
MIDDLEWARE = [
|
||||
#'django.middleware.security.SecurityMiddleware', # SECURE_SSL_REDIRECT and SECURE_SSL_HOST # we don't use this
|
||||
"django.middleware.gzip.GZipMiddleware", # not needed when expofiles and photos served by apache
|
||||
@@ -128,11 +128,12 @@ MIDDLEWARE = [
|
||||
#"troggle.core.middleware.TroggleAppendSlashMiddleware", # modified Feb.2025
|
||||
]
|
||||
|
||||
WSGI_APPLICATION = "troggle.wsgi.application" # change to asgi as soon as we upgrade to Django 3.0
|
||||
WSGI_APPLICATION = "troggle.wsgi.application" # change to asgi as soon as we upgrade to Django 5 ?
|
||||
# Append slash can't work if we have a universal catchall URL rule, and we do because all the handbook files
|
||||
# do not have simple prefix. This is why we used to have an /expoweb/ prefix for everything in the website.
|
||||
# APPEND_SLASH = True # using django.middleware.common.CommonMiddleware. Pointless, never happens if there is a catchall.
|
||||
# TROGGLE_APPEND_SLASH = True # this is our middleware: see the code in troggle/core/middleware.py for why we do NOT use it.
|
||||
# Also site-media etc.
|
||||
APPEND_SLASH = False # using django.middleware.common.CommonMiddleware which we need for other things (I think).
|
||||
|
||||
QM_PATTERN = r"\[\[\s*[Qq][Mm]:([ABC]?)(\d{4})-(\d*)-(\d*)\]\]"
|
||||
|
||||
# Re-enable TinyMCE when Dj upgraded to v3. Also templates/editexpopage.html
|
||||
|
||||
Reference in New Issue
Block a user