Remove support for django 1.0 CSRF as we only care about 1.2 or later

This commit is contained in:
Wookey 2013-07-02 18:12:18 +01:00
parent d1ad8730d7
commit 69c3a06c98

View File

@ -61,17 +61,12 @@ TEMPLATE_CONTEXT_PROCESSORS = ( "django.core.context_processors.auth", "core.con
LOGIN_REDIRECT_URL = '/'
if django.VERSION[0] >=1 and django.VERSION[1] > 1:
csrfmiddleware = 'django.middleware.csrf.CsrfViewMiddleware'
else:
csrfmiddleware = 'django.contrib.csrf.middleware.CsrfMiddleware'
MIDDLEWARE_CLASSES = (
'django.middleware.common.CommonMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.redirects.middleware.RedirectFallbackMiddleware',
csrfmiddleware,
'django.middleware.csrf.CsrfViewMiddleware',
'troggle.middleware.SmartAppendSlashMiddleware'
)