From bd5f8ddccdb8bc67cd559d3cfa2cd9ee8491262f Mon Sep 17 00:00:00 2001 From: Benjamin Ramser Date: Tue, 28 Dec 2021 11:18:44 +0100 Subject: [PATCH] fix: disable caller --- internal/log/log.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/internal/log/log.go b/internal/log/log.go index 6e6eca43..bdcfe3bc 100644 --- a/internal/log/log.go +++ b/internal/log/log.go @@ -36,8 +36,12 @@ func SetOutput(w io.Writer) { func Build(c string) error { if c == "" { zcfg := zap.NewProductionConfig() + // to be able to filter with Tile38 levels zcfg.Level.SetLevel(zap.DebugLevel) + // disable caller because caller is always log.go + zcfg.DisableCaller = true + core, err := zcfg.Build() if err != nil { return err @@ -50,8 +54,12 @@ func Build(c string) error { if err != nil { return err } + // to be able to filter with Tile38 levels zcfg.Level.SetLevel(zap.DebugLevel) + // disable caller because caller is always log.go + zcfg.DisableCaller = true + core, err := zcfg.Build() if err != nil { return err