github.com/sleungcy/cli@v7.1.0+incompatible/command/translatableerror/assign_droplet_error.go (about) 1 package translatableerror 2 3 // AssignDropletError is returned when assigning the current droplet of an app 4 // fails 5 type AssignDropletError struct { 6 Message string 7 } 8 9 func (AssignDropletError) Error() string { 10 return "Unable to assign droplet: {{.CloudControllerMessage}}" 11 } 12 13 func (e AssignDropletError) Translate(translate func(string, ...interface{}) string) string { 14 return translate(e.Error(), map[string]interface{}{ 15 "CloudControllerMessage": e.Message, 16 }) 17 }