@ -73,7 +73,7 @@ func newPeerSet() *peerSet {
func ( ps * peerSet ) registerSnapExtension ( peer * snap . Peer ) error {
func ( ps * peerSet ) registerSnapExtension ( peer * snap . Peer ) error {
// Reject the peer if it advertises `snap` without `eth` as `snap` is only a
// Reject the peer if it advertises `snap` without `eth` as `snap` is only a
// satellite protocol meaningful with the chain selection of `eth`
// satellite protocol meaningful with the chain selection of `eth`
if ! peer . Supports Cap( eth . ProtocolName , eth . ProtocolVersions ) {
if ! peer . Running Cap( eth . ProtocolName , eth . ProtocolVersions ) {
return errSnapWithoutEth
return errSnapWithoutEth
}
}
// Ensure nobody can double connect
// Ensure nobody can double connect
@ -101,7 +101,7 @@ func (ps *peerSet) registerSnapExtension(peer *snap.Peer) error {
// by the peerset.
// by the peerset.
func ( ps * peerSet ) waitSnapExtension ( peer * eth . Peer ) ( * snap . Peer , error ) {
func ( ps * peerSet ) waitSnapExtension ( peer * eth . Peer ) ( * snap . Peer , error ) {
// If the peer does not support a compatible `snap`, don't wait
// If the peer does not support a compatible `snap`, don't wait
if ! peer . Supports Cap( snap . ProtocolName , snap . ProtocolVersions ) {
if ! peer . Running Cap( snap . ProtocolName , snap . ProtocolVersions ) {
return nil , nil
return nil , nil
}
}
// Ensure nobody can double connect
// Ensure nobody can double connect