mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 18:32:23 +00:00
swarm/pss: func name changed
This commit is contained in:
parent
a7350bd7df
commit
3e7aa78e51
2 changed files with 3 additions and 3 deletions
|
|
@ -247,7 +247,7 @@ func testForwardMsg(t *testing.T, ps *Pss, c *testCase) {
|
|||
|
||||
resultMap := make(map[pot.Address]int)
|
||||
|
||||
defer func() { sendFunc = sendMessageProd }()
|
||||
defer func() { sendFunc = sendMsg }()
|
||||
sendFunc = func(_ *Pss, sp *network.Peer, _ *PssMsg) bool {
|
||||
if tries < nFails {
|
||||
tries++
|
||||
|
|
|
|||
|
|
@ -888,10 +888,10 @@ func (p *Pss) send(to []byte, topic Topic, msg []byte, asymmetric bool, key []by
|
|||
|
||||
// sendFunc is a helper function that tries to send a message and returns true on success.
|
||||
// It is set here for usage in production, and optionally overridden in tests.
|
||||
var sendFunc func(p *Pss, sp *network.Peer, msg *PssMsg) bool = sendMessageProd
|
||||
var sendFunc func(p *Pss, sp *network.Peer, msg *PssMsg) bool = sendMsg
|
||||
|
||||
// tries to send a message, returns true if successful
|
||||
func sendMessageProd(p *Pss, sp *network.Peer, msg *PssMsg) bool {
|
||||
func sendMsg(p *Pss, sp *network.Peer, msg *PssMsg) bool {
|
||||
var isPssEnabled bool
|
||||
info := sp.Info()
|
||||
for _, capability := range info.Caps {
|
||||
|
|
|
|||
Loading…
Reference in a new issue