From 5b906407d8c67d9e33224f61cbcf3853d903670b Mon Sep 17 00:00:00 2001 From: kaotisk Date: Tue, 15 Oct 2024 03:50:35 +0300 Subject: Possible fix --- client/js/radio_emulator.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/client/js/radio_emulator.js b/client/js/radio_emulator.js index 65a593b..a10f656 100644 --- a/client/js/radio_emulator.js +++ b/client/js/radio_emulator.js @@ -311,9 +311,8 @@ function listCallback(json, params) else if ( values.now_on_sequence > json.list[i].starts_on && values.now_on_sequence > json.list[i+1].starts_on ) { appendPreviouslyPlayedShows(json.list[i]); - ++i; - values.now_on_sequence = values.now_on_sequence - json.list[i].starts_on; - FetchJSON(`${jsonRequest}${json.list[i].hash}`, loadShowCallback, [json, values.now_on_sequence, json.list[i], hash_of_list]); + values.now_on_sequence = values.now_on_sequence - json.list[i+1].starts_on; + FetchJSON(`${jsonRequest}${json.list[i+1].hash}`, loadShowCallback, [json, values.now_on_sequence, json.list[i+1], hash_of_list]); debugLog('Second!'); break; } -- cgit v1.2.3