NewInternalServerError creates and returns 500 ApiError.
(message string, rawErrData any)
| 101 | |
| 102 | // NewInternalServerError creates and returns 500 ApiError. |
| 103 | func NewInternalServerError(message string, rawErrData any) *ApiError { |
| 104 | if message == "" { |
| 105 | message = "Something went wrong while processing your request." |
| 106 | } |
| 107 | |
| 108 | return NewApiError(http.StatusInternalServerError, message, rawErrData) |
| 109 | } |
| 110 | |
| 111 | func NewTooManyRequestsError(message string, rawErrData any) *ApiError { |
| 112 | if message == "" { |
searching dependent graphs…