From 7ee8ab7375bb6ea96fae43c840ab464ffc71c5ac Mon Sep 17 00:00:00 2001 From: Miguel Ángel Moreno Date: Fri, 26 Jan 2024 09:34:44 +0100 Subject: fix(frontend): further fix duration formatter --- src/frontend/tubo/util.cljs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src') diff --git a/src/frontend/tubo/util.cljs b/src/frontend/tubo/util.cljs index 4958437..9137cbe 100644 --- a/src/frontend/tubo/util.cljs +++ b/src/frontend/tubo/util.cljs @@ -18,7 +18,5 @@ (defn format-duration [num] (let [duration (js/Date. (* num 1000)) - slice (if (>= (.getHours duration) 1) - #(.slice % 11 19) - #(.slice % 14 19))] + slice #(.slice % (if (>= (.getUTCHours duration) 1) 11 14) 19)] (-> duration (.toISOString) slice))) -- cgit v1.2.3