mirror of
https://github.com/c0de-archive/spotipy.git
synced 2024-11-04 23:17:48 +00:00
ascii decode in _refresh_access_token
This commit is contained in:
parent
1737a550d3
commit
a3a68be7bc
@ -218,8 +218,8 @@ class SpotifyOAuth(object):
|
||||
payload = { 'refresh_token': refresh_token,
|
||||
'grant_type': 'refresh_token'}
|
||||
|
||||
auth_header = base64.b64encode(self.client_id + ':' + self.client_secret)
|
||||
headers = {'Authorization': 'Basic %s' % auth_header}
|
||||
auth_header = base64.b64encode(bytes(self.client_id + ':' + self.client_secret, encoding='utf-8'))
|
||||
headers = {'Authorization': 'Basic %s' % auth_header.decode('ascii')}
|
||||
|
||||
response = requests.post(self.OAUTH_TOKEN_URL, data=payload,
|
||||
headers=headers)
|
||||
|
Loading…
Reference in New Issue
Block a user