mirror of
https://github.com/astaxie/beego.git
synced 2024-11-22 08:10:58 +00:00
beego: setLogger return error
This commit is contained in:
parent
9c5ceb70cc
commit
12e1ab0f80
8
log.go
8
log.go
@ -31,8 +31,12 @@ func SetLogFuncCall(b bool) {
|
|||||||
var BeeLogger *logs.BeeLogger
|
var BeeLogger *logs.BeeLogger
|
||||||
|
|
||||||
// SetLogger sets a new logger.
|
// SetLogger sets a new logger.
|
||||||
func SetLogger(adaptername string, config string) {
|
func SetLogger(adaptername string, config string) error {
|
||||||
BeeLogger.SetLogger(adaptername, config)
|
err := BeeLogger.SetLogger(adaptername, config)
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// Trace logs a message at trace level.
|
// Trace logs a message at trace level.
|
||||||
|
Loading…
Reference in New Issue
Block a user