fix(log): Allow log without any provider
This commit is contained in:
parent
06f0722cdb
commit
aea5d74d53
@ -66,7 +66,7 @@ func InitFromCustomConfig(c *ConfigStruct) (*logrus.Logger, error) {
|
||||
|
||||
level, err := logrus.ParseLevel(*c.Level)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
return nil, errors.Trace(err)
|
||||
}
|
||||
|
||||
// init logger
|
||||
@ -94,7 +94,7 @@ func InitFromCustomConfig(c *ConfigStruct) (*logrus.Logger, error) {
|
||||
}
|
||||
log.AddHook(hook)
|
||||
case ProviderName_NONE:
|
||||
fallthrough
|
||||
// Do nothing, None can be use in case of StdOut Only.
|
||||
default:
|
||||
return nil, errors.BadRequestf("Provider is not handled.")
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user