Error returns the error message for the HTTPError.
()
| 48 | |
| 49 | // Error returns the error message for the HTTPError. |
| 50 | func (e *HTTPError) Error() string { |
| 51 | if e.Internal == nil { |
| 52 | return fmt.Sprintf("code=%d, message=%v", e.StatusCode, e.Msg) |
| 53 | } |
| 54 | return fmt.Sprintf("code=%d, message=%v, internal=%v", e.StatusCode, e.Msg, e.Internal) |
| 55 | } |
| 56 | |
| 57 | // Unwrap returns the internal error of the HTTPError. |
| 58 | func (e *HTTPError) Unwrap() error { |
no outgoing calls