withFailed method
Sets the response as failed.
failed
: Indicates if the operation failed.
Returns the modified Response object with updated failed status.
Implementation
Response<T> withFailed(bool failed) {
_failed = failed;
_loading = false;
return this;
}