Skip to content

Commit a8a773e

Browse files
author
Ben Rogers-Newsome
committed
Check whether user is still authenticated just after pipeline ends
We check if the user is authenticated before the pipeline runs but the structure of the pipeline allows for the user instance to change as the pipeline runs. We don't re-check whether the user is still authenticated before working out whether or not to log them in!
1 parent a1de109 commit a8a773e

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

social_core/actions.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ def do_complete(backend, login, user=None, redirect_name='next',
5555
if user and not isinstance(user, user_model):
5656
return user
5757

58+
is_authenticated = user_is_authenticated(user)
5859
if is_authenticated:
5960
if not user:
6061
url = setting_url(backend, redirect_value, 'LOGIN_REDIRECT_URL')

0 commit comments

Comments
 (0)