Skip to content

Commit f2d3cd3

Browse files
committed
keep method None if not passed to OAuth1RSA
Signed-off-by: Rocco, Marco <[email protected]>
1 parent 0df3be4 commit f2d3cd3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

oauth1/oauth_ext.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ def __init__(self, consumer_key: str, signing_key: PKey):
4949
self.signing_key = signing_key
5050

5151
def __call__(self, r: PreparedRequest):
52-
method = '' if r.method is None else r.method.upper()
52+
method = r.method.upper() if r.method is not None else r.method
5353
if all(v is not None for v in [r, self.consumer_key, self.signing_key]):
5454
r.headers['Authorization'] = \
5555
OAuth.get_authorization_header(uri=r.url,

0 commit comments

Comments
 (0)