Skip to content

Commit

Permalink
Merge pull request #304 from testwill/slice
Browse files Browse the repository at this point in the history
chore: slice loop replace
  • Loading branch information
aceld authored Mar 7, 2024
2 parents 92a4581 + a0b2f52 commit c7cf5bc
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions znet/heartbeat.go
Original file line number Diff line number Diff line change
Expand Up @@ -177,9 +177,7 @@ func (h *HeartbeatChecker) Clone() ziface.IHeartbeatChecker {
}

// deep copy routerSlices
for _, handler := range h.routerSlices {
heartbeat.routerSlices = append(heartbeat.routerSlices, handler)
}
heartbeat.routerSlices = append(heartbeat.routerSlices, h.routerSlices...)

return heartbeat
}
Expand Down

0 comments on commit c7cf5bc

Please sign in to comment.