mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-29 22:29:56 +02:00
Fix handling of draft term pages
By just removing the term page and all of its page entries. Fixes #12055
This commit is contained in:
@@ -1415,8 +1415,10 @@ func (sa *sitePagesAssembler) applyAggregatesToTaxonomiesAndTerms() error {
|
||||
if err := p.setMetaPost(cascade); err != nil {
|
||||
return false, err
|
||||
}
|
||||
|
||||
if err := sa.pageMap.treeTaxonomyEntries.WalkPrefix(
|
||||
if !p.s.shouldBuild(p) {
|
||||
sa.pageMap.treePages.Delete(s)
|
||||
sa.pageMap.treeTaxonomyEntries.DeletePrefix(paths.AddTrailingSlash(s))
|
||||
} else if err := sa.pageMap.treeTaxonomyEntries.WalkPrefix(
|
||||
doctree.LockTypeRead,
|
||||
paths.AddTrailingSlash(s),
|
||||
func(ss string, wn *weightedContentNode) (bool, error) {
|
||||
|
Reference in New Issue
Block a user