1
0
mirror of https://github.com/astaxie/beego.git synced 2024-11-21 22:00:54 +00:00

beego: setLogger return error

This commit is contained in:
asta.xie 2014-04-02 23:45:44 +08:00
parent 9c5ceb70cc
commit 12e1ab0f80

8
log.go
View File

@ -31,8 +31,12 @@ func SetLogFuncCall(b bool) {
var BeeLogger *logs.BeeLogger
// SetLogger sets a new logger.
func SetLogger(adaptername string, config string) {
BeeLogger.SetLogger(adaptername, config)
func SetLogger(adaptername string, config string) error {
err := BeeLogger.SetLogger(adaptername, config)
if err != nil {
return err
}
return nil
}
// Trace logs a message at trace level.