isClientError property

bool get isClientError

Returns true if the status code indicates a client error (4xx).

Implementation

bool get isClientError => statusCode >= 400 && statusCode < 500;