diff options
author | tdro <tdro@noreply.example.com> | 2022-12-06 23:43:53 -0500 |
---|---|---|
committer | tdro <tdro@noreply.example.com> | 2022-12-06 23:43:53 -0500 |
commit | 0f64a4206a109e4643aca07772d6091f9607068c (patch) | |
tree | 750152654fd316c5bd93b0503a1c55812e46795e /themes/default/layouts/_default/rss.xml | |
parent | cf600839a84be5245397c22658462edbea001157 (diff) | |
download | canory-0f64a4206a109e4643aca07772d6091f9607068c.tar.gz canory-0f64a4206a109e4643aca07772d6091f9607068c.tar.bz2 canory-0f64a4206a109e4643aca07772d6091f9607068c.zip |
themes/default/layouts/partials: Consolidate the content filter into a function
Diffstat (limited to 'themes/default/layouts/_default/rss.xml')
-rw-r--r-- | themes/default/layouts/_default/rss.xml | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/themes/default/layouts/_default/rss.xml b/themes/default/layouts/_default/rss.xml index 8248cc1..01f2aa6 100644 --- a/themes/default/layouts/_default/rss.xml +++ b/themes/default/layouts/_default/rss.xml @@ -52,6 +52,8 @@ {{- end -}} {{- end -}} +{{- $filteredPages := partial "function-filters-content.html" .Paginator.Pages -}} + {{- printf `<?xml version="1.0" encoding="utf-8" standalone="yes"?>` | safeHTML }} {{ printf `<?xml-stylesheet href="/rss.xsl" type="text/xsl"?>` | safeHTML }} @@ -77,7 +79,7 @@ {{ $atomPrevious }} {{ $atomNext }} - {{ range first $limit .Paginator.Pages }} + {{ range first $limit $filteredPages -}} {{- $author = partial "function-authors-data.html" . -}} {{- $profile = $author.picture.profile -}} @@ -104,7 +106,6 @@ {{- $atomAuthorUri = .Params.Feed.favicon | absURL -}} {{- end -}} - {{ if and (not .Params.Unlisted) (not .ExpiryDate) }} <item> <title>{{ .Summary | htmlUnescape }}</title> <link>{{ .Permalink }}</link> @@ -120,7 +121,7 @@ <atom:uri>{{ $atomAuthorUri }}</atom:uri> </atom:author> </item> - {{ end -}} - {{ end }} + + {{ end -}} </channel> </rss> |