DUPLICATE_VOTE evidence type

This commit is contained in:
Christopher Goes
2018-05-31 05:24:15 +02:00
parent 3bf9a7dc50
commit c9514f077b
+6 -2
View File
@@ -9,6 +9,11 @@ import (
"github.com/tendermint/tmlibs/merkle"
)
const (
// Evidence type for duplicate vote
DUPLICATE_VOTE = "DUPLICATE_VOTE"
)
// ErrEvidenceInvalid wraps a piece of evidence and the error denoting how or why it is invalid.
type ErrEvidenceInvalid struct {
Evidence Evidence
@@ -54,8 +59,7 @@ type DuplicateVoteEvidence struct {
// String returns a string representation of the evidence.
func (dve *DuplicateVoteEvidence) String() string {
return fmt.Sprintf("VoteA: %v; VoteB: %v", dve.VoteA, dve.VoteB)
return DUPLICATE_VOTE
}
// Height returns the height this evidence refers to.