mirror of
https://github.com/tendermint/tendermint.git
synced 2026-01-07 13:55:17 +00:00
privval: migrate to protobuf (#4985)
This commit is contained in:
@@ -108,13 +108,15 @@ func makeVote(header *types.Header, valset *types.ValidatorSet,
|
||||
Type: tmproto.PrecommitType,
|
||||
BlockID: blockID,
|
||||
}
|
||||
|
||||
v := vote.ToProto()
|
||||
// Sign it
|
||||
signBytes := vote.SignBytes(header.ChainID)
|
||||
// TODO Consider reworking makeVote API to return an error
|
||||
signBytes := types.VoteSignBytes(header.ChainID, v)
|
||||
sig, err := key.Sign(signBytes)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
vote.Signature = sig
|
||||
|
||||
return vote
|
||||
|
||||
Reference in New Issue
Block a user