aboutsummaryrefslogtreecommitdiffhomepage
path: root/tpl/fmt
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <[email protected]>2022-12-21 13:11:08 +0100
committerBjørn Erik Pedersen <[email protected]>2022-12-21 15:33:02 +0100
commitcd1ed563a82f8a9ebdd3109230e34e74bf5ec6eb (patch)
treed766a7d88e59d20be9380aaf3d45b799737a288e /tpl/fmt
parentaa2c724195ae53e698dfaa7f9bea63e5cecea391 (diff)
downloadhugo-cd1ed563a82f8a9ebdd3109230e34e74bf5ec6eb.tar.gz
hugo-cd1ed563a82f8a9ebdd3109230e34e74bf5ec6eb.zip
tpl: Improve template funcs GoDoc
Diffstat (limited to 'tpl/fmt')
-rw-r--r--tpl/fmt/fmt.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/tpl/fmt/fmt.go b/tpl/fmt/fmt.go
index 7790b4955..e767a3ea9 100644
--- a/tpl/fmt/fmt.go
+++ b/tpl/fmt/fmt.go
@@ -47,12 +47,12 @@ type Namespace struct {
distinctLogger loggers.IgnorableLogger
}
-// Print returns a string representation args.
+// Print returns a string representation of args.
func (ns *Namespace) Print(args ...any) string {
return _fmt.Sprint(args...)
}
-// Printf returns a formatted string representation of args.
+// Printf returns string representation of args formatted with the layouut in format.
func (ns *Namespace) Printf(format string, args ...any) string {
return _fmt.Sprintf(format, args...)
}
@@ -70,7 +70,7 @@ func (ns *Namespace) Errorf(format string, args ...any) string {
}
// Erroridf formats args according to a format specifier and logs an ERROR and
-// an information text that the error with the given ID can be suppressed in config.
+// an information text that the error with the given id can be suppressed in config.
// It returns an empty string.
func (ns *Namespace) Erroridf(id, format string, args ...any) string {
ns.distinctLogger.Errorsf(id, format, args...)