forked from expo/troggle
Add support for old and new (1.4 on) location for auth module.
This commit is contained in:
parent
0dfbd1c84f
commit
a376044fdf
@ -57,7 +57,12 @@ TEMPLATE_LOADERS = (
|
||||
# 'django.template.loaders.eggs.load_template_source',
|
||||
)
|
||||
|
||||
TEMPLATE_CONTEXT_PROCESSORS = ( "django.core.context_processors.auth", "core.context.troggle_context", )
|
||||
if django.VERSION[0] == 1 and django.VERSION[1] < 4:
|
||||
authmodule = 'django.core.context_processors.auth'
|
||||
else:
|
||||
authmodule = 'django.contrib.auth.context_processors.auth'
|
||||
|
||||
TEMPLATE_CONTEXT_PROCESSORS = ( authmodule, "core.context.troggle_context", )
|
||||
|
||||
LOGIN_REDIRECT_URL = '/'
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user