Skip to content

Commit

Permalink
Merge pull request #534 from mudler/fix/panic
Browse files Browse the repository at this point in the history
fix: do not prematurely close channel
  • Loading branch information
mudler authored Aug 11, 2024
2 parents 07f3ff8 + d061067 commit d339a44
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 d339a44

Please sign in to comment.