Skip to content

Commit de34ca3

Browse files
fviardposita
authored andcommitted
Fixes oauth.py (v2) to target dropbox api v2 and not v1.
1 parent c37a6bc commit de34ca3

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

dropbox/oauth.py

+2-4
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@
2424
url_path_quote = urllib.quote
2525
url_encode = urllib.urlencode
2626

27-
OAUTH_ROUTE_VERSION = '1'
28-
2927

3028
class OAuth2FlowNoRedirectResult(object):
3129
"""
@@ -153,9 +151,9 @@ def build_path(self, target, params=None):
153151

154152
if params:
155153
query_string = _params_to_urlencoded(params)
156-
return "/%s%s?%s" % (OAUTH_ROUTE_VERSION, target_path, query_string)
154+
return "%s?%s" % (target_path, query_string)
157155
else:
158-
return "/%s%s" % (OAUTH_ROUTE_VERSION, target_path)
156+
return target_path
159157

160158
def build_url(self, target, params=None):
161159
"""Build an API URL.

0 commit comments

Comments
 (0)