github.com/franc20/ayesa_sap@v7.0.0-beta.28.0.20200124003224-302d4d52fa6c+incompatible/command/translatableerror/process_not_found_error.go (about)

     1  package translatableerror
     2  
     3  // ProcessNotFoundError is returned when a process type can't be found
     4  type ProcessNotFoundError struct {
     5  	ProcessType string
     6  }
     7  
     8  func (ProcessNotFoundError) Error() string {
     9  	return "Process {{.ProcessType}} not found"
    10  }
    11  
    12  func (e ProcessNotFoundError) Translate(translate func(string, ...interface{}) string) string {
    13  	return translate(e.Error(), map[string]interface{}{
    14  		"ProcessType": e.ProcessType,
    15  	})
    16  }