初始化日志模块时应先重置beego默认的logger (#823)

pull/914/head v2.2-beta.1
lei_lei 2023-08-23 10:22:02 +08:00 committed by GitHub
parent 2e3aebe315
commit 18b6ead94d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -148,6 +148,7 @@ func RegisterModel() {
// RegisterLogger 注册日志
func RegisterLogger(log string) {
logs.Reset()
logs.SetLogFuncCall(true)
_ = logs.SetLogger("console")
logs.EnableFuncCallDepth(true)