diff options
author | Prabhu Ramachandran | 2018-01-08 16:00:38 +0530 |
---|---|---|
committer | GitHub | 2018-01-08 16:00:38 +0530 |
commit | f457585ea62ec76240edb9397c7f08a46f25947c (patch) | |
tree | b0d7f794d8484b6c781e8817be6dc90dfefd9395 | |
parent | 65ce10a9057d30e6a7e9a37926abdef97e5fdc48 (diff) | |
parent | 01e55880d2d9018c55435764d3c34338b91b5d77 (diff) | |
download | online_test-f457585ea62ec76240edb9397c7f08a46f25947c.tar.gz online_test-f457585ea62ec76240edb9397c7f08a46f25947c.tar.bz2 online_test-f457585ea62ec76240edb9397c7f08a46f25947c.zip |
Merge pull request #414 from adityacp/fix_oauth_login
Fix Oauth email verification
-rw-r--r-- | yaksh/pipeline/user.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/yaksh/pipeline/user.py b/yaksh/pipeline/user.py index 4aecd95..d5ec292 100644 --- a/yaksh/pipeline/user.py +++ b/yaksh/pipeline/user.py @@ -1,8 +1,11 @@ from yaksh.models import Profile -#from django.contrib.auth.models import User + def save_profile(backend, user, response, *args, **kwargs): if not hasattr(user, 'profile'): profile = Profile.objects.create(user=user) profile.roll_number = profile.id - profile.save() + else: + profile = Profile.objects.get(user=user) + profile.is_email_verified = True + profile.save() |