mirror of
https://github.com/PeernetOfficial/core.git
synced 2026-07-16 18:37:51 +01:00
Fix bug in PeerConnectNode
This commit is contained in:
@@ -251,7 +251,7 @@ func PeerConnectPublicKey(backend *core.Backend, publicKey *btcec.PublicKey, tim
|
||||
|
||||
// PeerConnectNode tries to connect via the node ID
|
||||
func PeerConnectNode(backend *core.Backend, nodeID []byte, timeout time.Duration) (peer *core.PeerInfo, err error) {
|
||||
if len(nodeID) == 256/8 {
|
||||
if len(nodeID) != 256/8 {
|
||||
return nil, errors.New("invalid node ID")
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user