From 4c941c6847fc7887cc484fb24474a1b296b5fe83 Mon Sep 17 00:00:00 2001 From: "Alexander \"Arav\" Andreev" Date: Tue, 8 Mar 2022 03:26:36 +0400 Subject: [PATCH] Let's comment out everything and debug it step by step. --- internal/handlers/web/templates/index.jade | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/internal/handlers/web/templates/index.jade b/internal/handlers/web/templates/index.jade index aae883c..846587e 100644 --- a/internal/handlers/web/templates/index.jade +++ b/internal/handlers/web/templates/index.jade @@ -29,12 +29,16 @@ html(lang='en') | OGG 128 Kb/s audio(preload='none' controls='') 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]. - - p Now playing: #[span#radio-song= .Status.SongName] - p Current/peak listeners: #[span#radio-listeners= .Status.Listeners] / #[span#radio-listener-peak= .Status.ListenerPeak] - p - small Notice: information updates every 45 seconds. But you can #[button(id='btn-update') update] it forcibly. + //- | Your browser doesn't support an audio element, it's sad... But you always can take the #[a(href='/playlist') playlist]. + //- - var isDateNA = .Status.ServerStartDate == 'n/a' + //- unless false + //- p #[span#radio-status On-air since #[time(datetime=.Status.ServerStartISO8601)= .Status.ServerStartDate]] + //- else + //- p #[span#radio-status Radio is offline.] + //- p Now playing: #[span#radio-song= .Status.SongName] + //- p Current/peak listeners: #[span#radio-listeners= .Status.Listeners] / #[span#radio-listener-peak= .Status.ListenerPeak] + //- p + //- small Notice: information updates every 45 seconds. But you can #[button(id='btn-update') update] it forcibly. if (.Status.LastSongs) section h2 Last 10 songs @@ -45,7 +49,7 @@ html(lang='en') td= song.Artist td= song.Title section - p The largest number of simultaneous listeners was #[b 7] at #[time(datetime='2022-02-19') 19 February 2022], and the song was "Röyksopp - 49 Percent". + //- p The largest number of simultaneous listeners was #[b 7] at #[time(datetime='2022-02-19') 19 February 2022], and the song was "Röyksopp - 49 Percent". section h2 Privacy statements p Logs are collected and include access date and time, IP-address, User-Agent, referer URL, request. This website makes use of JavaScript to update a radio status and last 10 songs list.