swarm/kademlia: change overrun in discovery simulation PR due to rebasing

This commit is contained in:
stolen 2018-04-16 12:43:59 +02:00
parent 74828b81ae
commit b8d878a54d

View file

@ -263,14 +263,10 @@ func (k *Kademlia) SuggestPeer() (a OverlayAddr, o int, want bool) {
if po >= depth {
return false
}
ok := f(func(val pot.Val, _ int) bool {
return f(func(val pot.Val, _ int) bool {
a = k.callable(val)
return a == nil
})
if !ok {
return false
}
return true
})
// found a candidate
if a != nil {