Skip to content

Commit b675f01

Browse files
committed
🐛 fix except wrong target
1 parent 1b7497f commit b675f01

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

SpotifyLyricWindow/common/api/user_api/user_api.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
from collections import namedtuple
55

66
import requests
7+
import json
78

89
from common.api.exceptions import *
910
from common.api.user_api.user_auth import SpotifyUserAuth
@@ -105,7 +106,7 @@ def _player_http(self, method, url_suffix, **kwargs):
105106
res_json = res.json()
106107
if res_json.get("error") and res_json.get("error").get('reason') == 'PREMIUM_REQUIRED':
107108
raise NoPermission("Premium required!")
108-
except requests.JSONDecodeError:
109+
except json.JSONDecodeError:
109110
pass
110111
return res
111112

0 commit comments

Comments
 (0)