Skip to content

Commit 87a8fc7

Browse files
committed
fix(rss): hide private/unlisted pages in RSS feed
1 parent 9b2f680 commit 87a8fc7

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

modules/blox/layouts/rss.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
{{- /* Upstream Hugo bug - RSS dates can be in future: https://github.com/gohugoio/hugo/issues/3918 */ -}}
33
{{- $page_context := cond .IsHome site . -}}
44
{{- $pages := $page_context.RegularPages -}}
5+
{{- $pages = where $pages "Params.private" "!=" true -}}
56
{{- $limit := site.Config.Services.RSS.Limit -}}
67
{{- if ge $limit 1 -}}
78
{{- $pages = $pages | first $limit -}}

0 commit comments

Comments
 (0)