From d2cc93d5c732bb42781f2b20ee96dc0b0b5f422b Mon Sep 17 00:00:00 2001 From: Jimmy Cai Date: Sun, 6 Sep 2020 20:33:23 +0200 Subject: [PATCH] fix(article/footer): display last updated time only when it's different to article publish time --- layouts/partials/article/components/footer.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/layouts/partials/article/components/footer.html b/layouts/partials/article/components/footer.html index 5663a24..3b281bc 100644 --- a/layouts/partials/article/components/footer.html +++ b/layouts/partials/article/components/footer.html @@ -14,7 +14,7 @@ {{ end }} - {{- if not .Lastmod.IsZero -}} + {{- if ne .Lastmod .Date -}}
{{ (resources.Get "icons/clock.svg").Content | safeHTML }} Last updated on {{ .Lastmod.Format ( or .Site.Params.dateFormat "Jan 02, 2006 15:04 MST" ) }}