From 5171911342a11882ddff93db006c05c7a3f3075f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nacho=20Cord=C3=B3n?= Date: Fri, 14 Apr 2017 21:04:24 +0200 Subject: [PATCH] Changes critical is not for != --- spotipy/oauth2.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/spotipy/oauth2.py b/spotipy/oauth2.py index b339918..88375ce 100644 --- a/spotipy/oauth2.py +++ b/spotipy/oauth2.py @@ -73,7 +73,7 @@ class SpotifyClientCredentials(object): response = requests.post(self.OAUTH_TOKEN_URL, data=payload, headers=headers, verify=True, proxies=self.proxies) - if response.status_code is not 200: + if response.status_code != 200: raise SpotifyOauthError(response.reason) token_info = response.json() return token_info @@ -214,7 +214,7 @@ class SpotifyOAuth(object): response = requests.post(self.OAUTH_TOKEN_URL, data=payload, headers=headers, verify=True, proxies=self.proxies) - if response.status_code is not 200: + if response.status_code != 200: raise SpotifyOauthError(response.reason) token_info = response.json() token_info = self._add_custom_values_to_token_info(token_info)