submitHttpRequest method

Future<HttpResponse> submitHttpRequest(
  1. HttpClient client,
  2. HttpRequest request,
  3. ProgressListener? progressListener,
  4. bool log,
)

Implementation

Future<HttpResponse> submitHttpRequest(HttpClient client, HttpRequest request,
    ProgressListener? progressListener, bool log) {
  setupUserAgent(client.userAgent);

  if (!client.hasInterceptor) {
    return doHttpRequest(client, request, progressListener, log);
  }

  return doHttpRequest(client, request, progressListener, log)
      .then((response) => client._interceptResponse(response));
}