mirror of
https://github.com/astaxie/beego.git
synced 2024-11-26 07:01:28 +00:00
update the log call deep
This commit is contained in:
parent
2288ac868c
commit
304beaf89f
@ -154,7 +154,7 @@ func (bl *BeeLogger) writerMsg(loglevel int, msg string) error {
|
|||||||
lm := new(logMsg)
|
lm := new(logMsg)
|
||||||
lm.level = loglevel
|
lm.level = loglevel
|
||||||
if bl.enableFuncCallDepth {
|
if bl.enableFuncCallDepth {
|
||||||
_, file, line, ok := runtime.Caller(bl.loggerFuncCallDepth + 1)
|
_, file, line, ok := runtime.Caller(bl.loggerFuncCallDepth)
|
||||||
if ok {
|
if ok {
|
||||||
_, filename := path.Split(file)
|
_, filename := path.Split(file)
|
||||||
lm.msg = fmt.Sprintf("[%s:%d] %s", filename, line, msg)
|
lm.msg = fmt.Sprintf("[%s:%d] %s", filename, line, msg)
|
||||||
|
Loading…
Reference in New Issue
Block a user