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/fmt
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2020-10-21 12:17:48 +0300
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2020-10-22 10:09:29 +0300
commitfdfa4a5fe62232f65f1dd8d6fe0c500374228788 (patch)
treeb804e91506a7f3c58690c6fd774b28f95184d5dc /tpl/fmt
parent8cbe2bbfad6aa4de267921e24e166d4addf47040 (diff)
Allow getJSON errors to be ignored
This change is mostly motivated to get a more stable CI build (we're building the Hugo site there, with Instagram and Twitter shortcodes sometimes failing). Fixes #7866
Diffstat (limited to 'tpl/fmt')
-rw-r--r--tpl/fmt/fmt.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/tpl/fmt/fmt.go b/tpl/fmt/fmt.go
index 924d27a1d..780add0d1 100644
--- a/tpl/fmt/fmt.go
+++ b/tpl/fmt/fmt.go
@@ -24,8 +24,8 @@ import (
// New returns a new instance of the fmt-namespaced template functions.
func New(d *deps.Deps) *Namespace {
ns := &Namespace{
- errorLogger: helpers.NewDistinctLogger(d.Log.ERROR),
- warnLogger: helpers.NewDistinctLogger(d.Log.WARN),
+ errorLogger: helpers.NewDistinctLogger(d.Log.Error()),
+ warnLogger: helpers.NewDistinctLogger(d.Log.Warn()),
}
d.BuildStartListeners.Add(func() {