• Type guard to check if an error is an HTTP error with a response status code. This safely narrows the type without unsafe type assertions.

    Parameters

    • error: unknown

      The error to check

    Returns error is { response: { status: number } }

    True if the error has a response.status property