From: Joe Mooring Date: Thu, 20 Jul 2023 19:29:25 +0000 (-0700) Subject: tpl/collections: Fix description of apply function X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=dc2a544fa;p=brevno-suite%2Fhugo tpl/collections: Fix description of apply function The collections.Apply template function cannot be used with maps. --- diff --git a/tpl/collections/apply.go b/tpl/collections/apply.go index 1dc09c8e5..397ba0fdb 100644 --- a/tpl/collections/apply.go +++ b/tpl/collections/apply.go @@ -24,7 +24,7 @@ import ( "github.com/gohugoio/hugo/tpl" ) -// Apply takes a map, array, or slice c and returns a new slice with the function fname applied over it. +// Apply takes an array or slice c and returns a new slice with the function fname applied over it. func (ns *Namespace) Apply(ctx context.Context, c any, fname string, args ...any) (any, error) { if c == nil { return make([]any, 0), nil