updateContentLength method
void
updateContentLength()
Implementation
void updateContentLength() {
var sendDataLength = _sendDataLength(updateToBytes: true);
if (sendDataLength != null) {
var contentLength = headerContentLength;
var transferEncoding = headerTransferEncoding;
if (contentLength == null &&
(transferEncoding == null || transferEncoding.contains('chunked'))) {
var requestHeaders = _requestHeaders ??= <String, String>{};
requestHeaders[HttpRequest._headerKeyContentLength] = '$sendDataLength';
}
}
}