Skip to content

Commit

Permalink
fix: πŸ› Change pipeline as per new response from login api (#40)
Browse files Browse the repository at this point in the history
  • Loading branch information
aashutoshrathi authored May 2, 2020
1 parent 79afc7e commit eee850c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions landing/pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ def get_profile(backend, user, response, details, *args, **kwargs):
small_url = None
profile = Profile.objects.get_or_create(user=user)[0]
if backend.name == "google-oauth2":
if response['image'].get('url'):
small_url = response['image'].get('url')
url = small_url.replace("sz=50", "sz=160")
if response['picture']:
small_url = response['picture']
url = small_url
profile.avatar_small = small_url
profile.avatar = url
profile.save()

0 comments on commit eee850c

Please sign in to comment.