wrap it
parent
9a3c76c263
commit
85338887b4
|
@ -125,7 +125,10 @@ class Itunes(object):
|
|||
response = self._request('GET', '/playlists')
|
||||
playlists = response.get('playlists', [])
|
||||
|
||||
found_playlists = [playlist for playlist in playlists if playlist["name"] == playlist_id_or_name or playlist["id"] == playlist_id_or_name]
|
||||
found_playlists = [playlist for playlist in \
|
||||
playlists if playlist["name"] == playlist_id_or_name or \
|
||||
playlist["id"] == playlist_id_or_name]
|
||||
|
||||
if len(found_playlists) > 0:
|
||||
playlist = found_playlists[0]
|
||||
return self._request('PUT', '/playlists/' + playlist['id'] + '/play')
|
||||
|
|
Loading…
Reference in New Issue