mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-03 16:56:54 +00:00
37_Spotify: saved tracks offset
git-svn-id: https://svn.fhem.de/fhem/trunk@14486 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
38a167c74e
commit
0040b3bf20
@ -524,7 +524,7 @@ sub Spotify_playSavedTracks($$$) { # play users saved tracks
|
||||
my $name = $hash->{NAME};
|
||||
|
||||
$device_id = $first . (defined $device_id ? " " . $device_id : "") if(defined $first && $first !~ /^[0-9]+$/);
|
||||
$first = 1 if(!defined $first || !$first !~ /^[0-9]+$/);
|
||||
$first = 1 if(!defined $first || $first !~ /^[0-9]+$/);
|
||||
|
||||
Spotify_apiRequest($hash, 'me/tracks?limit=50'. ($first > 50 ? '&offset='. int($first/50)-1 : ''), undef, 'GET', 1); # getting saved tracks
|
||||
my $result = $hash->{helper}{dispatch}{json}{items};
|
||||
|
Loading…
x
Reference in New Issue
Block a user