// proceed only when the message is not received before and this consensus phase is not done.
shouldProcess:=true
consensus.mutex.Lock()
// check consensus Id
ifconsensusId!=consensus.consensusId{
shouldProcess=false
consensus.Log.Debug("[ERROR] Received RESPONSE with wrong consensus Id","myConsensusId",consensus.consensusId,"theirConsensusId",consensusId,"consensus",consensus)
return
}
// proceed only when the message is not received before and this consensus phase is not done.
consensus.mutex.Lock()
_,ok:=consensus.responses[validatorId]
shouldProcess:=!ok
shouldProcess=shouldProcess&&!ok
ifshouldProcess{
consensus.responses[validatorId]=validatorId
//consensus.Log.Debug("Number of responses received", "count", len(consensus.responses), "consensudId", consensusId)