github.com/sleungcy-sap/cli@v7.1.0+incompatible/command/translatableerror/api_request_error.go (about) 1 package translatableerror 2 3 type APIRequestError struct { 4 Err error 5 } 6 7 func (APIRequestError) Error() string { 8 return "Request error: {{.Error}}\nTIP: If you are behind a firewall and require an HTTP proxy, verify the https_proxy environment variable is correctly set. Else, check your network connection." 9 } 10 11 func (e APIRequestError) Translate(translate func(string, ...interface{}) string) string { 12 return translate(e.Error(), map[string]interface{}{ 13 "Error": e.Err, 14 }) 15 }