fix(rss): hide private/unlisted pages in RSS feed

This commit is contained in:
George Cushen committed 2026-04-08 19:02:34 +01:00
1 parent 9b2f6809f3
commit 87a8fc714e
1 file changed
+1
+1
View File
@@ -2,6 +2,7 @@
{{- /* Upstream Hugo bug - RSS dates can be in future: https://github.com/gohugoio/hugo/issues/3918 */ -}}
{{- $page_context := cond .IsHome site . -}}
{{- $pages := $page_context.RegularPages -}}
{{- $pages = where $pages "Params.private" "!=" true -}}
{{- $limit := site.Config.Services.RSS.Limit -}}
{{- if ge $limit 1 -}}
{{- $pages = $pages | first $limit -}}