Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/gohugoio/hugo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tpl
diff options
context:
space:
mode:
authorJoe Mooring <joe.mooring@veriphor.com>2021-11-01 20:43:41 +0300
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2021-11-01 20:54:43 +0300
commit04a3b45db4cd28b4821b5c98cd67dfbf1d098957 (patch)
treecda314834fe9579279cb79a8d1ec90a5c60a4ab3 /tpl
parent0cc39af68232f1a4981aae2e72cf65da762b5768 (diff)
Fix description of lang.FormatNumberCustom
It currently refers to itself as a simple alternative, when it should refer to lang.FormatNumber.
Diffstat (limited to 'tpl')
-rw-r--r--tpl/lang/lang.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/tpl/lang/lang.go b/tpl/lang/lang.go
index 3fb321e1a..b593ccfe6 100644
--- a/tpl/lang/lang.go
+++ b/tpl/lang/lang.go
@@ -20,8 +20,8 @@ import (
"strconv"
"strings"
- translators "github.com/gohugoio/localescompressed"
"github.com/gohugoio/locales"
+ translators "github.com/gohugoio/localescompressed"
"github.com/pkg/errors"
"github.com/gohugoio/hugo/deps"
@@ -138,7 +138,7 @@ func (ns *Namespace) castPrecisionNumber(precision, number interface{}) (uint64,
// Note that numbers are rounded up at 5 or greater.
// So, with precision set to 0, 1.5 becomes `2`, and 1.4 becomes `1`.
//
-// For a simpler function that adapts to the current language, see FormatNumberCustom.
+// For a simpler function that adapts to the current language, see FormatNumber.
func (ns *Namespace) FormatNumberCustom(precision, number interface{}, options ...interface{}) (string, error) {
prec, err := cast.ToIntE(precision)
if err != nil {