From: Christopher Allan Webber Date: Sun, 31 Jul 2011 20:09:52 +0000 (-0500) Subject: We should redirect after verify_email to the user's homepage X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=269943a645d16c51af0388c764c76721336369bc;p=mediagoblin.git We should redirect after verify_email to the user's homepage --- diff --git a/mediagoblin/auth/views.py b/mediagoblin/auth/views.py index fb5db870..df7e2a88 100644 --- a/mediagoblin/auth/views.py +++ b/mediagoblin/auth/views.py @@ -145,23 +145,19 @@ def verify_email(request): user['status'] = u'active' user['email_verified'] = True user.save() - verification_successful = True messages.add_message( request, messages.SUCCESS, ('Your email address has been verified. ' 'You may now login, edit your profile, and submit images!')) else: - verification_successful = False messages.add_message(request, messages.ERROR, 'The verification key or user id is incorrect') - return render_to_response( - request, - 'mediagoblin/user_pages/user.html', - {'user': user, - 'verification_successful' : verification_successful}) + return redirect( + request, 'mediagoblin.user_pages.user_home', + user=request.user['username']) def resend_activation(request):