Merge pull request #6358 from jonyhy96/feat-error

refactor: functions for error log and error return
This commit is contained in:
Phil Estes
2021-12-14 10:16:54 -05:00
committed by GitHub
30 changed files with 80 additions and 80 deletions

View File

@@ -359,7 +359,7 @@ func (s *Server) Stop() {
instance, err := p.Instance()
if err != nil {
log.L.WithError(err).WithField("id", p.Registration.URI()).
Errorf("could not get plugin instance")
Error("could not get plugin instance")
continue
}
closer, ok := instance.(io.Closer)
@@ -368,7 +368,7 @@ func (s *Server) Stop() {
}
if err := closer.Close(); err != nil {
log.L.WithError(err).WithField("id", p.Registration.URI()).
Errorf("failed to close plugin")
Error("failed to close plugin")
}
}
}