summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorReorx <novoreorx@gmail.com>2022-09-07 00:38:45 +0800
committerReorx <novoreorx@gmail.com>2022-09-07 00:38:45 +0800
commit3bc70e9a2cdc3dd3185c8b3a9a513e999dbd0023 (patch)
tree3b0cdbd4b3261c24df5c136847cdd02e5c069986
parent8bbb2ac5b5281bd2707fb1ea799852f08c9be57b (diff)
fix hidden is shown in list.html (section page)
-rw-r--r--layouts/_default/list.html2
1 files changed, 1 insertions, 1 deletions
diff --git a/layouts/_default/list.html b/layouts/_default/list.html
index 6ab2cde..e2c248c 100644
--- a/layouts/_default/list.html
+++ b/layouts/_default/list.html
@@ -26,10 +26,10 @@
{{- $pages := .Pages }}
-
{{- if .IsHome }}
{{- $pages = where site.RegularPages "Type" "in" site.Params.mainSections }}
{{- end }}
+{{- $pages = where $pages "Params.hidden" "!=" true }}
{{/* related issue: https://github.com/gohugoio/hugo/issues/9003 */}}
{{ $paginator := "" }}