Skip to content

Commit a184c53

Browse files
tastapodjmooring
authored andcommitted
[PATCH] tpl/tplimpl: Fix incorrect lastBuildDate
cherry-pick from gohugoio/hugo@87bf2b9 Co-authored-by: Joe Mooring <joe@mooring.com>
1 parent 66904cc commit a184c53

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

layouts/_default/rss.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@
6060
<managingEditor>{{.}}{{ with $authorName }} ({{ . }}){{ end }}</managingEditor>{{ end }}{{ with $authorEmail }}
6161
<webMaster>{{ . }}{{ with $authorName }} ({{ . }}){{ end }}</webMaster>{{ end }}{{ with site.Copyright }}
6262
<copyright>{{ . }}</copyright>{{ end }}{{ if not .Date.IsZero }}
63-
<lastBuildDate>{{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}</lastBuildDate>{{ end }}
63+
<lastBuildDate>{{ (index $pages.ByLastmod.Reverse 0).Lastmod.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}</lastBuildDate>{{ end }}
6464
{{- with .OutputFormats.Get "RSS" }}
6565
{{ printf "<atom:link href=%q rel=\"self\" type=%q />" .Permalink .MediaType | safeHTML }}
6666
{{- end }}

0 commit comments

Comments
 (0)