Fix error if the user hasn't set api credentials
commit275b37cc7c87b562d08576be5268a4f8797b84ea
author0xhtml <34682885+0xhtml@users.noreply.github.com>
dateWed 31 Jul 2019, 21:01 (7 years ago)
parentae3eeed
searx/engines/spotify.py+1−1
@@ -39,7 +39,7 @@ def request(query, params):
3939 'https://accounts.spotify.com/api/token',
4040 data={'grant_type': 'client_credentials'},
4141 headers={'Authorization': 'Basic ' + str(base64.b64encode(
42− (api_client_id + ":" + api_client_secret).encode('utf-8')
42+ "{}:{}".format(api_client_id, api_client_secret).encode('utf-8')
4343 ), 'utf-8')}
4444 )
4545 j = loads(r.text)