fix: need to set self on message handler
This commit is contained in:
parent
ed48f60b12
commit
24e2b3a79f
|
@ -83,6 +83,7 @@ func (s *SignedMessage) HandleMessage(node interfaces.Node, peer net.Peer, verif
|
||||||
|
|
||||||
if msgHandler, valid := GetMessageType(types.ProtocolMethod(payload.kind)); valid {
|
if msgHandler, valid := GetMessageType(types.ProtocolMethod(payload.kind)); valid {
|
||||||
msgHandler.SetIncomingMessage(s)
|
msgHandler.SetIncomingMessage(s)
|
||||||
|
msgHandler.SetSelf(msgHandler)
|
||||||
err := msgpack.Unmarshal(payload.message, &msgHandler)
|
err := msgpack.Unmarshal(payload.message, &msgHandler)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
|
|
Loading…
Reference in New Issue