diff options
| author | Gary Wilson Jr <gary.wilson@gmail.com> | 2008-08-15 17:10:14 +0000 |
|---|---|---|
| committer | Gary Wilson Jr <gary.wilson@gmail.com> | 2008-08-15 17:10:14 +0000 |
| commit | 415bf3efb3bac1f14efc77d5bdea7a4fddef03de (patch) | |
| tree | bdaf23105cf1241065b2a8eaf1882fb658d4c415 /django/contrib/auth/views.py | |
| parent | 90c67e0f55800ec3ffbb05c5e90c28ccfa9234d4 (diff) | |
Fixed #7364 -- Never cache the contrib.auth login view.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@8383 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'django/contrib/auth/views.py')
| -rw-r--r-- | django/contrib/auth/views.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/django/contrib/auth/views.py b/django/contrib/auth/views.py index 16524fe42a..ba54f07991 100644 --- a/django/contrib/auth/views.py +++ b/django/contrib/auth/views.py @@ -14,6 +14,7 @@ from django.utils.http import urlquote, base36_to_int from django.utils.html import escape from django.utils.translation import ugettext as _ from django.contrib.auth.models import User +from django.views.decorators.cache import never_cache import re def login(request, template_name='registration/login.html', redirect_field_name=REDIRECT_FIELD_NAME): @@ -43,6 +44,7 @@ def login(request, template_name='registration/login.html', redirect_field_name= redirect_field_name: redirect_to, 'site_name': current_site.name, }, context_instance=RequestContext(request)) +login = never_cache(login) def logout(request, next_page=None, template_name='registration/logged_out.html'): "Logs out the user and displays 'You are logged out' message." |
