docs: add mod name to log

master
Evan Chen 2021-11-24 23:13:00 +08:00
parent a084c9e004
commit 072c7d04d7
1 changed files with 2 additions and 1 deletions

View File

@ -20,6 +20,7 @@ var index string
var servePublic = http.FileServer(http.FS(public.FS))
var tmpl *engine.Engine
var l = log.With().Str("mod", "kconfig").Logger()
func init() {
tmpl = engine.Must(engine.New("").Parse(index))
@ -44,7 +45,7 @@ func New() *Kconfig {
AppName: "kconfig",
Schema: defaultSchema,
Apply: func(b []byte) error {
log.Debug().Msgf("%s", b)
l.Debug().Msgf("%s", b)
return nil
},
Load: func() []byte {