Skip to content

Commit 3a1b52e

Browse files
committed
Removed print statement and updated OAuth doc examples.
1 parent bf69f57 commit 3a1b52e

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

dropbox/oauth.py

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -123,10 +123,6 @@ def _finish(self, code, redirect_uri):
123123

124124
d = resp.json()
125125

126-
access_token = d["access_token"]
127-
user_id = d["uid"]
128-
print('BASE', d)
129-
130126
return OAuth2FlowNoRedirectResult(
131127
d['access_token'],
132128
d['account_id'],
@@ -193,12 +189,12 @@ class DropboxOAuth2FlowNoRedirect(DropboxOAuth2FlowBase):
193189
auth_code = raw_input("Enter the authorization code here: ").strip()
194190
195191
try:
196-
access_token, user_id = auth_flow.finish(auth_code)
192+
oauth_result = auth_flow.finish(auth_code)
197193
except Exception, e:
198194
print('Error: %s' % (e,))
199195
return
200196
201-
dbx = Dropbox(access_token)
197+
dbx = Dropbox(oauth_result.access_token)
202198
"""
203199

204200
def __init__(self, consumer_key, consumer_secret, locale=None):
@@ -268,7 +264,7 @@ def dropbox_auth_start(web_app_session, request):
268264
# URL handler for /dropbox-auth-finish
269265
def dropbox_auth_finish(web_app_session, request):
270266
try:
271-
access_token, user_id, url_state = \\
267+
oauth_result = \\
272268
get_dropbox_auth_flow(web_app_session).finish(
273269
request.query_params)
274270
except BadRequestException, e:

0 commit comments

Comments
 (0)