From 3bc70e9a2cdc3dd3185c8b3a9a513e999dbd0023 Mon Sep 17 00:00:00 2001 From: Reorx Date: Wed, 7 Sep 2022 00:38:45 +0800 Subject: [PATCH] fix hidden is shown in list.html (section page) --- layouts/_default/list.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 := "" }}