From 942e5c37e7301ef0e5e6735cd82829b27e2f02e6 Mon Sep 17 00:00:00 2001 From: stjet <49297268+stjet@users.noreply.github.com> Date: Fri, 19 Jul 2024 01:16:41 +0000 Subject: [PATCH] empty playlist item bug fix --- templates/player.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/player.html b/templates/player.html index 8c4c5cb..6f02c8c 100644 --- a/templates/player.html +++ b/templates/player.html @@ -303,7 +303,7 @@ } async function add_selected_playlist() { - let playlist_songs = (await (await fetch(`/playlists/${document.getElementById("playlist-select").value}`)).text()).split("\n"); + let playlist_songs = (await (await fetch(`/playlists/${document.getElementById("playlist-select").value}`)).text()).split("\n").filter((p) => p.trim() !== ""); add_playlist(playlist_songs); }