Merge pull request #158 from josduj/master

Fixes error when scope is not set
This commit is contained in:
Paul Lamere 2017-01-18 17:58:22 -05:00 committed by GitHub
commit dc996b363f
1 changed files with 4 additions and 2 deletions

View File

@ -153,8 +153,10 @@ class SpotifyOAuth(object):
pass
def _is_scope_subset(self, needle_scope, haystack_scope):
needle_scope = set(needle_scope.split())
haystack_scope = set(haystack_scope.split())
if needle_scope:
needle_scope = set(needle_scope.split())
if haystack_scope:
haystack_scope = set(haystack_scope.split())
return needle_scope <= haystack_scope