Commits

offline committed 1957672

reset password bugfixes

Comments (0)

Files changed (3)

openauth/signals.py

             auth.login(request, user)
             
     elif confirmation_type == openauth.settings.PASSWORD_RESET_TYPE:
+        user = instance
         user.backend = 'django.contrib.auth.backends.ModelBackend'
         auth.login(request, user)    
 
     url(r'^openid-complete/$', views.openid_complete, name='openauth-openid-complete'),
     url(r'^openid-registration/$', views.openid_registration, name='openauth-openid-registration'),
     url(r'^logout/$', views.logout, name='openauth-logout'),
-    url(r'^reset_password/$', views.reset_password, name='openauth-reset-password'),
-    url(r'^change_password/$', views.change_password, name='openauth-change-password'),
+    url(r'^reset-password/$', views.reset_password, name='openauth-reset-password'),
+    url(r'^change-password/$', views.change_password, name='openauth-change-password'),
     url(r'^user/$', views.show_user, name='openauth-show-user'),
     url(r'^user/(\d+)/$', views.show_user, name='openauth-show-user'),
     url(r'^users/$', views.users, name='openauth-show-users'),

openauth/views.py

     return {'form': form}
 
 
-@login_required
+@login_required(opposite=True)
 @render_to('openauth/reset_password.html')
 def reset_password(request):
     if request.POST:
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.