github.com/pokt-network/tendermint@v0.32.11-0.20230426215212-59310158d3e9/evidence/errors.go (about)

     1  package evidence
     2  
     3  import (
     4  	"fmt"
     5  )
     6  
     7  // ErrInvalidEvidence returns when evidence failed to validate
     8  type ErrInvalidEvidence struct {
     9  	Reason error
    10  }
    11  
    12  func (e ErrInvalidEvidence) Error() string {
    13  	return fmt.Sprintf("evidence is not valid: %v ", e.Reason)
    14  }
    15  
    16  // ErrEvidenceAlreadyStored indicates that the evidence has already been stored in the evidence db
    17  type ErrEvidenceAlreadyStored struct{}
    18  
    19  func (e ErrEvidenceAlreadyStored) Error() string {
    20  	return "evidence is already stored"
    21  }