mirror of
https://github.com/c0de-archive/spotipy.git
synced 2025-01-06 14:52:50 +00:00
Token cache handles null scopes correctly
This commit is contained in:
parent
7499d8e511
commit
dab5e08b7a
@ -153,11 +153,8 @@ class SpotifyOAuth(object):
|
|||||||
pass
|
pass
|
||||||
|
|
||||||
def _is_scope_subset(self, needle_scope, haystack_scope):
|
def _is_scope_subset(self, needle_scope, haystack_scope):
|
||||||
if needle_scope:
|
needle_scope = set(needle_scope.split()) if needle_scope else set()
|
||||||
needle_scope = set(needle_scope.split())
|
haystack_scope = set(haystack_scope.split()) if haystack_scope else set()
|
||||||
if haystack_scope:
|
|
||||||
haystack_scope = set(haystack_scope.split())
|
|
||||||
|
|
||||||
return needle_scope <= haystack_scope
|
return needle_scope <= haystack_scope
|
||||||
|
|
||||||
def is_token_expired(self, token_info):
|
def is_token_expired(self, token_info):
|
||||||
|
Loading…
Reference in New Issue
Block a user