Skip to content

Commit

Permalink
Merge f51ebbe into 624ad01
Browse files Browse the repository at this point in the history
  • Loading branch information
lukeburden committed Aug 21, 2019
2 parents 624ad01 + f51ebbe commit 59ca404
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions rest_auth/registration/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,10 @@ def validate(self, attrs):
login.lookup()
login.save(request, connect=True)

# we return the login data (and so User and SocialAccount instances) here
# such that custom login and connect views can render suitable responses
attrs['login'] = login
# we still return `user` here for backwards compatibility
attrs['user'] = login.account.user

return attrs
Expand Down

0 comments on commit 59ca404

Please sign in to comment.