From 22eeeac42b7032fa45b449f1807bfcc0899b721e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Arne=20Schl=C3=BCter?= Date: Tue, 9 Oct 2018 11:50:35 +0200 Subject: [PATCH] Correctly inflect "track" in collection info --- src/cljs/airsonic_ui/components/collection/views.cljs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/cljs/airsonic_ui/components/collection/views.cljs b/src/cljs/airsonic_ui/components/collection/views.cljs index 524584b..734c8c5 100644 --- a/src/cljs/airsonic_ui/components/collection/views.cljs +++ b/src/cljs/airsonic_ui/components/collection/views.cljs @@ -17,7 +17,8 @@ (defn collection-info [{:keys [songCount duration year]}] (vec (cond-> [:ul.is-smaller.collection-info - [:li [icon :audio-spectrum] (str songCount " tracks")] + [:li [icon :audio-spectrum] (str songCount (if (= 1 songCount) + " track" " tracks"))] [:li [icon :clock] (format-duration duration)]] year (conj [:li [icon :calendar] (str "Released in " year)]))))