fix message type to make it working with deploy.sh

pull/569/head
Minh Doan 6 years ago committed by Minh Doan
parent 4e98699ecf
commit 0bc22a5784
  1. 7
      drand/drand_validator.go

@ -17,9 +17,12 @@ func (dRand *DRand) ProcessMessageValidator(payload []byte) {
utils.GetLogInstance().Error("Failed to unmarshal message payload.", "err", err, "dRand", dRand)
}
if message.Type == msg_pb.MessageType_DRAND_INIT {
switch message.Type {
case msg_pb.MessageType_DRAND_INIT:
dRand.processInitMessage(message)
} else {
case msg_pb.MessageType_DRAND_COMMIT:
// do nothing on the COMMIT message, as it is intended to send to leader
default:
utils.GetLogInstance().Error("Unexpected message type", "msgType", message.Type, "dRand", dRand)
}
}

Loading…
Cancel
Save