disable stack trace in debug

master v0.0.6
Evan Chen 2021-11-07 18:49:54 +08:00
parent 31689a002d
commit 2bbc6ae9ff
1 changed files with 5 additions and 4 deletions

9
log.go
View File

@ -115,10 +115,11 @@ func (l *Logger) output(lev Llevel, depth int, fields H, v ...interface{}) {
if !PROD {
data.Stack = stack()
}
case Ldebug:
if !PROD {
data.Stack = stack()
}
// disable stack trace on debug
// case Ldebug:
// if !PROD {
// data.Stack = stack()
// }
}
lock.Lock()
defer lock.Unlock()