Skip to content
This repository has been archived by the owner on Oct 22, 2019. It is now read-only.

Commit

Permalink
Added signup redirect for SIGNIN_AFTER_SIGNUP
Browse files Browse the repository at this point in the history
  • Loading branch information
Rsgm committed Aug 18, 2016
1 parent 4cc10c6 commit 4c038a0
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions userena/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,11 @@ def signup(request, signup_form=SignupForm,
user = authenticate(identification=user.email, check_password=False)
login(request, user)

# since we signed in the user and have no more information to display,
# we can redirect the user to a requested page
if redirect_url:
redirect_to = redirect_url

return redirect(redirect_to)

if not extra_context: extra_context = dict()
Expand Down

0 comments on commit 4c038a0

Please sign in to comment.