(
public status: number,
public body: unknown,
message: string,
)
| 2 | |
| 3 | export class ApiError extends Error { |
| 4 | constructor( |
| 5 | public status: number, |
| 6 | public body: unknown, |
| 7 | message: string, |
| 8 | ) { |
| 9 | super(message); |
| 10 | this.name = "ApiError"; |
| 11 | } |
| 12 | } |
| 13 | |
| 14 | async function request<T>(path: string, init?: RequestInit): Promise<T> { |
nothing calls this directly
no outgoing calls
no test coverage detected