From 35f6be96fdcf7325b43c80cf0b9dac1ca06eeafb Mon Sep 17 00:00:00 2001 From: Philip Rosenberg-Watt Date: Wed, 13 Nov 2019 12:59:06 -0700 Subject: Fix RSS New template, adapted. --- layouts/rss.xml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/layouts/rss.xml b/layouts/rss.xml index 12dedab..aeb7526 100644 --- a/layouts/rss.xml +++ b/layouts/rss.xml @@ -1,9 +1,11 @@ -{{- $pages := .Data.Pages -}} +{{- $pctx := . -}} +{{- if .IsHome -}}{{ $pctx = .Site }}{{- end -}} +{{- $pages := $pctx.RegularPages -}} {{- $limit := .Site.Config.Services.RSS.Limit -}} {{- if ge $limit 1 -}} {{- $pages = $pages | first $limit -}} {{- end -}} -{{- printf "" | safeHTML }} +{{- printf "" | safeHTML }} {{ if eq .Title .Site.Title }}{{ .Site.Title }}{{ else }}{{ with .Title }}{{.}} on {{ end }}{{ .Site.Title }}{{ end }} -- cgit v1.2.3