From: Janez Stupar Date: Sun, 11 Mar 2012 23:29:59 +0000 (+0100) Subject: Transfer redirect parameter (?next=) into new session. May come handy in our next... X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=1fdb665b37bfc0de9871c2ea6031ed0a54ee3e6f;p=django-social-auth.git Transfer redirect parameter (?next=) into new session. May come handy in our next view. --- diff --git a/social_auth/views.py b/social_auth/views.py index ad92fa2..7790d6a 100644 --- a/social_auth/views.py +++ b/social_auth/views.py @@ -166,6 +166,8 @@ def complete_process(request, backend, *args, **kwargs): # user.social_user is the used UserSocialAuth instance defined # in authenticate process social_user = user.social_user + if redirect_value: + request.session[REDIRECT_FIELD_NAME] = redirect_value or DEFAULT_REDIRECT if setting('SOCIAL_AUTH_SESSION_EXPIRATION', True): # Set session expiration date if present and not disabled by