diff options
-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() |