Skip to content

Commit

Permalink
remove nils from p2p logs (#10329)
Browse files Browse the repository at this point in the history
Copy PR #10303 into `main`

Co-authored-by: Alex Sharov <AskAlexSharov@gmail.com>
  • Loading branch information
yperbasis and AskAlexSharov authored May 14, 2024
1 parent 9ded704 commit 627c3dc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion p2p/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -1221,7 +1221,7 @@ func (srv *Server) listErrors() []interface{} {
srv.errorsMu.Lock()
defer srv.errorsMu.Unlock()

list := make([]interface{}, len(srv.errors)*2)
list := make([]interface{}, 0, len(srv.errors)*2)
for err, count := range srv.errors {
list = append(list, err, count)
}
Expand Down

0 comments on commit 627c3dc

Please sign in to comment.