[Django 1.6] Make pre-1.6 password reset links still work.

We can revert this commit once any previously valid password reset
links would have expired.

(imported from commit ffac4d36e914e77ad1516ccfac26318c79ba0f7f)
This commit is contained in:
Tim Abbott 2013-11-01 15:10:41 -04:00
parent 402547fa3f
commit f8208263ec
1 changed files with 8 additions and 0 deletions

View File

@ -38,6 +38,14 @@ urlpatterns = patterns('',
{'post_reset_redirect' : '/accounts/password/done/',
'template_name': 'zerver/reset_confirm.html',
'set_password_form' : zerver.forms.LoggingSetPasswordForm}),
# the next line can be removed PASSWORD_RESET_TIMEOUT_DAYS after this code is deployed
url(r'^reset/(?P<uidb36>[0-9A-Za-z]+)-(?P<token>.+)/$',
'django.contrib.auth.views.password_reset_confirm_uidb36',
{'post_reset_redirect' : '/accounts/password/done/',
'template_name': 'zerver/reset_confirm.html',
'set_password_form' : zerver.forms.LoggingSetPasswordForm}),
url(r'^accounts/password/done/$', 'django.contrib.auth.views.password_reset_complete',
{'template_name': 'zerver/reset_done.html'}),