]> git.maquefel.me Git - brevno-suite/hugo/commitdiff
tpl/tplimpl: Fix incorrect lastBuildDate
authorDaniel Terhorst-North <daniel@dannorth.net>
Wed, 1 Nov 2023 16:35:26 +0000 (16:35 +0000)
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>
Thu, 25 Jan 2024 18:46:52 +0000 (19:46 +0100)
Fixes #11600

Co-authored-by: Joe Mooring <joe@mooring.com>
tpl/tplimpl/embedded/templates/_default/rss.xml

index c997be31c4ddedb9f665ed05379bf1e321c0219d..eb5ed7d48e9a039f2bf5acc7c776d41fc3acda4b 100644 (file)
@@ -53,7 +53,7 @@
     <managingEditor>{{.}}{{ with $authorName }} ({{ . }}){{ end }}</managingEditor>{{ end }}{{ with $authorEmail }}
     <webMaster>{{ . }}{{ with $authorName }} ({{ . }}){{ end }}</webMaster>{{ end }}{{ with .Site.Copyright }}
     <copyright>{{ . }}</copyright>{{ end }}{{ if not .Date.IsZero }}
-    <lastBuildDate>{{ (index $pages.ByLastmod.Reverse 0).Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}</lastBuildDate>{{ end }}
+    <lastBuildDate>{{ (index $pages.ByLastmod.Reverse 0).Lastmod.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}</lastBuildDate>{{ end }}
     {{- with .OutputFormats.Get "RSS" }}
     {{ printf "<atom:link href=%q rel=\"self\" type=%q />" .Permalink .MediaType | safeHTML }}
     {{- end }}