diff options
Diffstat (limited to 'tpl')
-rw-r--r-- | tpl/tplimpl/embedded/templates.autogen.go | 3 | ||||
-rw-r--r-- | tpl/tplimpl/embedded/templates/_default/rss.xml | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/tpl/tplimpl/embedded/templates.autogen.go b/tpl/tplimpl/embedded/templates.autogen.go index e2d1d3c39..93713f00c 100644 --- a/tpl/tplimpl/embedded/templates.autogen.go +++ b/tpl/tplimpl/embedded/templates.autogen.go @@ -19,7 +19,8 @@ package embedded // EmbeddedTemplates represents all embedded templates. var EmbeddedTemplates = [][2]string{ {`_default/robots.txt`, `User-agent: *`}, - {`_default/rss.xml`, `{{- $pages := .Data.Pages -}} + {`_default/rss.xml`, `{{- $pages := .Pages -}} +{{- if .IsHome -}}{{- $pages = .Site.RegularPages -}}{{- end -}} {{- $limit := .Site.Config.Services.RSS.Limit -}} {{- if ge $limit 1 -}} {{- $pages = $pages | first $limit -}} diff --git a/tpl/tplimpl/embedded/templates/_default/rss.xml b/tpl/tplimpl/embedded/templates/_default/rss.xml index 675ecd43c..a3f58010e 100644 --- a/tpl/tplimpl/embedded/templates/_default/rss.xml +++ b/tpl/tplimpl/embedded/templates/_default/rss.xml @@ -1,4 +1,5 @@ -{{- $pages := .Data.Pages -}} +{{- $pages := .Pages -}} +{{- if .IsHome -}}{{- $pages = .Site.RegularPages -}}{{- end -}} {{- $limit := .Site.Config.Services.RSS.Limit -}} {{- if ge $limit 1 -}} {{- $pages = $pages | first $limit -}} |