We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 39735bf commit ebc9c18Copy full SHA for ebc9c18
src/workerd/api/global-scope.c++
@@ -204,6 +204,7 @@ kj::Promise<DeferredProxy<void>> ServiceWorkerGlobalScope::request(kj::HttpMetho
204
// If the request doesn't specify "Content-Length" or "Transfer-Encoding", set "Content-Length"
205
// to the body length if it's known. This ensures handlers for worker-to-worker requests can
206
// access known body lengths if they're set, without buffering bodies.
207
+ // TODO(cleanup): It would be nice if kj::HttpHeaders had an inlined has method
208
if (body != kj::none && newHeaders.get(kj::HttpHeaderId::CONTENT_LENGTH) == kj::none &&
209
newHeaders.get(kj::HttpHeaderId::TRANSFER_ENCODING) == kj::none) {
210
KJ_IF_SOME(l, requestBody.tryGetLength()) {
0 commit comments