summaryrefslogtreecommitdiff
path: root/yaksh/views.py
diff options
context:
space:
mode:
authorPrabhu Ramachandran2017-05-25 17:42:42 +0530
committerGitHub2017-05-25 17:42:42 +0530
commit80b67d07ceaf4c73705a27ee0bfc905e30b19ac4 (patch)
treed828f6f7697438d8addf04140f6c32bd005aaf6f /yaksh/views.py
parent7baaa70c0e7f660ad7482c3c3950eab171b27cd3 (diff)
parente6ab47d2ea99b703e3c261ad5e7b6785f6f8d5d5 (diff)
downloadonline_test-80b67d07ceaf4c73705a27ee0bfc905e30b19ac4.tar.gz
online_test-80b67d07ceaf4c73705a27ee0bfc905e30b19ac4.tar.bz2
online_test-80b67d07ceaf4c73705a27ee0bfc905e30b19ac4.zip
Merge pull request #296 from adityacp/fix_email_verfication_bug
Fix email verfication bug
Diffstat (limited to 'yaksh/views.py')
-rw-r--r--yaksh/views.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/yaksh/views.py b/yaksh/views.py
index c7af5cc..7db0366 100644
--- a/yaksh/views.py
+++ b/yaksh/views.py
@@ -1543,7 +1543,10 @@ def new_activation(request, email=None):
user.profile.key_expiry_time = timezone.now() + \
timezone.timedelta(minutes=20)
user.profile.save()
- success, msg = send_user_mail(user.email, user.profile.activation_key)
+ new_user_data = User.objects.get(email=email)
+ success, msg = send_user_mail(new_user_data.email,
+ new_user_data.profile.activation_key
+ )
if success:
context['activation_msg'] = msg
else:
@@ -1555,6 +1558,8 @@ def new_activation(request, email=None):
context_instance=ci)
def update_email(request):
+ context = {}
+ ci = RequestContext(request)
if request.method == "POST":
email = request.POST.get('email')
username = request.POST.get('username')