checkResponse static method

void checkResponse(
  1. Response response
)

Implementation

static void checkResponse(Response response) {
  if (response.statusCode >= 200 && response.statusCode < 400) return;
  throw ApiException.fromResponse(response);
}