From c3b96cf5fe1692dd65c0e456d79f1577e90e7467 Mon Sep 17 00:00:00 2001 From: Ashley Date: Sun, 5 Feb 2023 08:42:44 +0000 Subject: [PATCH] fix some silly issues :3 --- html/channel.ejs | 46 ++++++++++++++++++++++++++++++++++------------ 1 file changed, 34 insertions(+), 12 deletions(-) diff --git a/html/channel.ejs b/html/channel.ejs index 0c67cb7c..7e752663 100644 --- a/html/channel.ejs +++ b/html/channel.ejs @@ -548,14 +548,21 @@ white-space: nowrap;text-decoration: none;" href="/feeds/videos.xml?channel_id=< <% if (!tab) { %> Videos - <% if (Array.isArray(shorts.videos)) { %> + +<% if (Array.isArray(shorts.videos)) { %> +<% if (turntomins(shorts.videos[0].lengthSeconds) != "aN:aN" ) { %> Shorts <% } %> + <% } %> + <% if (Array.isArray(stream.videos)) { %> +<% if (turntomins(stream.videos[0].lengthSeconds) != "aN:aN" ) { %> Live <% } %> + <% } %> + <% if (Array.isArray(c.comments)) { %> <% if (c.comments.length != "0") { %> @@ -570,15 +577,20 @@ white-space: nowrap;text-decoration: none;" href="/feeds/videos.xml?channel_id=< <% if (tab === "about") { %> Videos - <% if (Array.isArray(shorts.videos)) { %> +<% if (Array.isArray(shorts.videos)) { %> +<% if (turntomins(shorts.videos[0].lengthSeconds) != "aN:aN" ) { %> Shorts <% } %> - - <% if (Array.isArray(stream.videos)) { %> + <% } %> - Live + <% if (Array.isArray(stream.videos)) { %> +<% if (turntomins(stream.videos[0].lengthSeconds) != "aN:aN" ) { %> + + Live <% } %> + <% } %> + <% if (Array.isArray(c.comments)) { %> <% if (c.comments.length != "0") { %> @@ -593,14 +605,19 @@ white-space: nowrap;text-decoration: none;" href="/feeds/videos.xml?channel_id=< <% if (tab === "community") { %> Videos - <% if (Array.isArray(shorts.videos)) { %> + <% if (Array.isArray(shorts.videos)) { %> +<% if (turntomins(shorts.videos[0].lengthSeconds) != "aN:aN" ) { %> Shorts <% } %> - <% if (Array.isArray(stream.videos)) { %> + <% } %> + + <% if (Array.isArray(stream.videos)) { %> +<% if (turntomins(stream.videos[0].lengthSeconds) != "aN:aN" ) { %> Live <% } %> + <% } %> Community @@ -610,15 +627,17 @@ white-space: nowrap;text-decoration: none;" href="/feeds/videos.xml?channel_id=< <% if (tab === "shorts") { %> Videos - <% if (Array.isArray(shorts.videos)) { %> +<% if (Array.isArray(shorts.videos)) { %> Shorts <% } %> - <% if (Array.isArray(stream.videos)) { %> + <% if (Array.isArray(stream.videos)) { %> +<% if (turntomins(stream.videos[0].lengthSeconds) != "aN:aN" ) { %> Live <% } %> - + <% } %> + <% if (Array.isArray(c.comments)) { %> <% if (c.comments.length != "0") { %> @@ -633,10 +652,13 @@ white-space: nowrap;text-decoration: none;" href="/feeds/videos.xml?channel_id=< <% if (tab === "live") { %> Videos - <% if (Array.isArray(shorts.videos)) { %> +<% if (Array.isArray(shorts.videos)) { %> +<% if (turntomins(shorts.videos[0].lengthSeconds) != "aN:aN" ) { %> Shorts <% } %> + <% } %> + <% if (Array.isArray(stream.videos)) { %> Live @@ -941,7 +963,7 @@ width: fit-content; <% if (stream.continuation) { %>
- Next Page + Next Page
<% } %>