mirror of https://github.com/status-im/go-waku.git
fix: remove useless condition
This commit is contained in:
parent
982707e02c
commit
94d20ab122
|
@ -3,7 +3,6 @@ package discv5
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"crypto/ecdsa"
|
"crypto/ecdsa"
|
||||||
"errors"
|
|
||||||
"math/rand"
|
"math/rand"
|
||||||
"net"
|
"net"
|
||||||
"sync"
|
"sync"
|
||||||
|
@ -382,10 +381,6 @@ func (d *DiscoveryV5) FindNodes(ctx context.Context, topic string, opts ...disco
|
||||||
limit = MaxPeersToDiscover
|
limit = MaxPeersToDiscover
|
||||||
}
|
}
|
||||||
|
|
||||||
if limit > MaxPeersToDiscover {
|
|
||||||
return nil, errors.New("limit should be less than allowed maximum")
|
|
||||||
}
|
|
||||||
|
|
||||||
// We are ignoring the topic. Future versions might use a map[string]*peerCache instead where the string represents the pubsub topic
|
// We are ignoring the topic. Future versions might use a map[string]*peerCache instead where the string represents the pubsub topic
|
||||||
|
|
||||||
d.peerCache.Lock()
|
d.peerCache.Lock()
|
||||||
|
|
Loading…
Reference in New Issue