common/hcontext: Replace with external package

This commit is contained in:
Bjørn Erik Pedersen
2025-08-21 21:58:43 +02:00
parent 13b43e6117
commit 186934feb4
7 changed files with 26 additions and 65 deletions

View File

@@ -26,8 +26,9 @@ import (
maps0 "maps"
"github.com/bep/helpers/contexthelpers"
"github.com/bep/logg"
"github.com/gohugoio/hugo/common/hcontext"
"github.com/gohugoio/hugo/common/herrors"
"github.com/gohugoio/hugo/common/hugio"
"github.com/gohugoio/hugo/common/hugo"
@@ -673,7 +674,7 @@ const (
contextKeyContentCallback contextKey = iota
)
var setGetContentCallbackInContext = hcontext.NewContextDispatcher[func(*pageContentOutput, contentTableOfContents)](contextKeyContentCallback)
var setGetContentCallbackInContext = contexthelpers.NewContextDispatcher[func(*pageContentOutput, contentTableOfContents)](contextKeyContentCallback)
func (c *cachedContentScope) contentToC(ctx context.Context) (contentTableOfContents, error) {
cp := c.pco