Skip to content

Commit

Permalink
fix: do not prematurely close channel
Browse files Browse the repository at this point in the history
Signed-off-by: mudler <[email protected]>
  • Loading branch information
mudler committed Aug 11, 2024
1 parent f60d1aa commit d061067
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/discovery/dht.go
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ func (d *DHT) FindClosePeers(ll log.StandardLogger, onlyStaticRelays bool, stati
if !onlyStaticRelays {
closestPeers, err := d.GetClosestPeers(ctx, d.PeerID().String())
if err != nil {
close(peerChan)
ll.Debug("Error getting closest peers: ", err)
}

for _, p := range closestPeers {
Expand Down

0 comments on commit d061067

Please sign in to comment.