github.com/LukasHeimann/cloudfoundrycli/v8@v8.4.4/command/translatableerror/revision_not_found.go (about)

     1  package translatableerror
     2  
     3  // RevisionNotFoundError is returned when a requested revision is not
     4  // found.
     5  type RevisionNotFoundError struct {
     6  	Version int
     7  }
     8  
     9  func (e RevisionNotFoundError) Error() string {
    10  	return "Revision '{{.RevisionVersion}}' not found"
    11  }
    12  
    13  func (e RevisionNotFoundError) Translate(translate func(string, ...interface{}) string) string {
    14  	return translate(e.Error(), map[string]interface{}{
    15  		"RevisionVersion": e.Version,
    16  	})
    17  }