mirror of
https://github.com/c0de-archive/spotipy.git
synced 2024-11-05 07:27:47 +00:00
Fixed (byte)string handling when calling base64 lib
This commit is contained in:
parent
1f833afa45
commit
f19682cc80
@ -185,8 +185,8 @@ class SpotifyOAuth(object):
|
|||||||
if self.state:
|
if self.state:
|
||||||
payload['state'] = self.state
|
payload['state'] = self.state
|
||||||
|
|
||||||
auth_header = base64.b64encode(self.client_id + ':' + self.client_secret)
|
auth_header = base64.b64encode(str(self.client_id + ':' + self.client_secret).encode())
|
||||||
headers = {'Authorization': 'Basic %s' % auth_header}
|
headers = {'Authorization': 'Basic %s' % auth_header.decode()}
|
||||||
|
|
||||||
|
|
||||||
response = requests.post(self.OAUTH_TOKEN_URL, data=payload,
|
response = requests.post(self.OAUTH_TOKEN_URL, data=payload,
|
||||||
|
Loading…
Reference in New Issue
Block a user