chore: fmt modify

This commit is contained in:
guoguangwu
2023-06-08 12:08:48 +08:00
parent 27ae25ec12
commit e71815cf03
5 changed files with 8 additions and 8 deletions

View File

@@ -81,7 +81,7 @@ func (el *esLogger) Init(config string) error {
if len(el.Formatter) > 0 {
fmtr, ok := logs.GetFormatter(el.Formatter)
if !ok {
return errors.New(fmt.Sprintf("the formatter with name: %s not found", el.Formatter))
return fmt.Errorf("the formatter with name: %s not found", el.Formatter)
}
el.formatter = fmtr
}