(statusCode int, status string, response ToolErrorResponseRecord)
| 66 | const nilToolErrorString = "<nil>" |
| 67 | |
| 68 | func newToolAPIError(statusCode int, status string, response ToolErrorResponseRecord) *toolAPIError { |
| 69 | return &toolAPIError{ |
| 70 | statusCode: statusCode, |
| 71 | status: strings.TrimSpace(status), |
| 72 | response: sanitizeToolErrorResponse(response), |
| 73 | } |
| 74 | } |
| 75 | |
| 76 | func (e *toolAPIError) Error() string { |
| 77 | if e == nil { |