Add refine rss build logic
This commit is contained in:
parent
711d4c7749
commit
c3c7351089
1 changed files with 4 additions and 2 deletions
|
@ -1,10 +1,12 @@
|
|||
{{- $pctx := . -}}
|
||||
{{- if .IsHome -}}{{ $pctx = .Site }}{{- end -}}
|
||||
{{- $pages := slice -}}
|
||||
{{- if or $.IsHome $.IsSection -}}
|
||||
{{- if $.IsHome -}}
|
||||
{{- $pages = $pctx.RegularPages -}}
|
||||
{{- else if $.IsSection -}}
|
||||
{{- $pages = $pctx.RegularPagesRecursive -}}
|
||||
{{- else -}}
|
||||
{{- $pages = $pctx.Pages -}}
|
||||
{{- $pages = $pctx.RegularPagesRecursive -}}
|
||||
{{- end -}}
|
||||
{{- $limit := .Site.Config.Services.RSS.Limit -}}
|
||||
{{- if ge $limit 1 -}}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue