Update p2p/base_reactor.go

Co-authored-by: Callum Waters <cmwaters19@gmail.com>
This commit is contained in:
William Banfield
2022-10-25 14:15:01 -04:00
committed by GitHub
parent 53502b22cb
commit 8e24fab5b5

View File

@@ -38,12 +38,8 @@ type Reactor interface {
// or other reason).
RemovePeer(peer Peer, reason interface{})
// Receive is called by the switch when a message is received from the peer.
//
// NOTE reactor can not keep msgBytes around after Receive completes without
// copying.
//
// CONTRACT: msgBytes are not nil.
// Receive is called by the switch when an envelope is received from any connected
// peer on any of the channels registered by the reactor
Receive(Envelope)
}