From 238705b00f0904dea243d2c54fa80dbc3138b823 Mon Sep 17 00:00:00 2001 From: "Alexander \"Arav\" Andreev" Date: Sat, 7 Oct 2023 05:25:13 +0400 Subject: [PATCH] In an index.pug file make a copy of a current song for thread safety. --- web/templates/index.pug | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/templates/index.pug b/web/templates/index.pug index 9ed6342..e5fb7b6 100644 --- a/web/templates/index.pug +++ b/web/templates/index.pug @@ -45,7 +45,7 @@ html(lang='en') source(src='/live/stream.ogg' type='audio/ogg') | Your browser doesn't support an audio element, it's sad... But you always can take the #[a(href='/playlist') playlist]! div - - cur := songList.Current() + - cur := *songList.Current() if (cur.Artist != "") p Now playing: #[span#radio-song #{cur.ArtistTitle()}] ( #[span#radio-duration-estimate ] #[span#radio-duration #{cur.DurationString()}] ) else