Fix veirfier retrieval

This commit is contained in:
David Avsajanishvili 2013-04-11 00:35:04 +01:00
parent 814170dc23
commit 900f8cae32

View file

@ -37,7 +37,6 @@ def begin_auth(request):
# Then send them over there, durh. # Then send them over there, durh.
request.session['request_token'] = auth_props request.session['request_token'] = auth_props
request.session['request_verifier'] = request.GET.get('oauth_verifier', None)
return HttpResponseRedirect(auth_props['auth_url']) return HttpResponseRedirect(auth_props['auth_url'])
def thanks(request, redirect_url=settings.LOGIN_REDIRECT_URL): def thanks(request, redirect_url=settings.LOGIN_REDIRECT_URL):
@ -60,8 +59,7 @@ def thanks(request, redirect_url=settings.LOGIN_REDIRECT_URL):
) )
# Retrieve the tokens we want... # Retrieve the tokens we want...
authorized_tokens = twitter.get_authorized_tokens( authorized_tokens = twitter.get_authorized_tokens(request.GET['oauth_verifier'])
request.session['request_verifier'])
# If they already exist, grab them, login and redirect to a page displaying stuff. # If they already exist, grab them, login and redirect to a page displaying stuff.
try: try: