This commit is contained in:
wangchuxiao 2023-01-12 17:30:40 +08:00
parent 8be1ee90f6
commit 57928f900e

View File

@ -179,7 +179,7 @@ func SetContextInfo(ctx context.Context, funcName string, logLevel logrus.Level,
funcInfo.FuncName = funcName
funcInfo.Err = err
funcInfo.LogLevel = logLevel
_, file, line, _ := runtime.Caller(0)
_, file, line, _ := runtime.Caller(2)
var s string
i := strings.SplitAfter(file, "/")
if len(i) > 3 {