summaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
authorFrancis Lavoie <lavofr@gmail.com>2021-03-29 13:03:50 -0400
committerGitHub <noreply@github.com>2021-03-29 11:03:50 -0600
commit911c8a371aa162d8b82812c3dd0662288fea76e0 (patch)
tree2f3af51cc312f3e1d15d033f2fc0f5771ae6cb99 /cmd
parent87fbc0783ae45cff885d5118a095ad9ac8c1c08a (diff)
cmd: Use formatted logger for config adapter warnings (#4080)
Diffstat (limited to 'cmd')
-rw-r--r--cmd/main.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/cmd/main.go b/cmd/main.go
index 886391b..14408fa 100644
--- a/cmd/main.go
+++ b/cmd/main.go
@@ -185,7 +185,7 @@ func loadConfig(configFile, adapterName string) ([]byte, string, error) {
if warn.Directive != "" {
msg = fmt.Sprintf("%s: %s", warn.Directive, warn.Message)
}
- fmt.Printf("[WARNING][%s] %s:%d: %s\n", adapterName, warn.File, warn.Line, msg)
+ caddy.Log().Warn(msg, zap.String("adapter", adapterName), zap.String("file", warn.File), zap.Int("line", warn.Line))
}
config = adaptedConfig
}