Skip to content

fix some error %s that should be %v due to possible nil error #238

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 16, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion cmd/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ func serverFunc(cmd *cobra.Command, args []string) (err error) {
rootCancel()
// wait for server stop
waitForServerStop := <-errc
log.Warn("closed server; %s", waitForServerStop)
log.Warn("closed server: %v", waitForServerStop)
case serverClosed := <-errc:
// server already stopped here
_ = rootCancel
Expand Down
4 changes: 2 additions & 2 deletions server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ func (s *server) Run(rootCtx context.Context) (err error) {
s.log.Warn("root context is done")

if !s.cfg.GwDisabled {
s.log.Warn("closed gRPC gateway server: %s", s.gwServer.Close())
s.log.Warn("closed gRPC gateway server: %v", s.gwServer.Close())
<-gwErrc
}

Expand All @@ -198,7 +198,7 @@ func (s *server) Run(rootCtx context.Context) (err error) {
case err = <-gRPCErrc:
s.log.Warn("gRPC server failed: %s", err)
if !s.cfg.GwDisabled {
s.log.Warn("closed gRPC gateway server: %s", s.gwServer.Close())
s.log.Warn("closed gRPC gateway server: %v", s.gwServer.Close())
<-gwErrc
}

Expand Down