set to always start at a random song regardless of shuffle status unless URL is passed

This commit is contained in:
2022-07-16 23:11:52 -05:00
parent df116510e4
commit 53ccbee8f4

View File

@@ -10,7 +10,7 @@
var g_playlist = null;
var g_previous = [];
var g_previous_idx = 0;
var g_current = 1;
var g_current = -1;
var g_looping = false;
var g_shuffle = true;
var MAX_HISTORY = 10;
@@ -105,7 +105,7 @@
return;
if (g_previous_idx >= (g_previous.length - 1)) {
if (g_shuffle) {
if (g_shuffle || g_current === -1) {
g_current = Math.floor (Math.random () * g_playlist.length);
}
else {