Skip to content

Commit a922ec0

Browse files
committed
Check request[bodyInternals] before accessing size.
1 parent 0f29581 commit a922ec0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/remix/src/utils/web-fetch.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ export const normalizeRemixRequest = (request: RemixRequest): Record<string, any
8888
contentLengthValue = '0';
8989
}
9090

91-
if (request.body !== null) {
91+
if (request.body !== null && request[bodyInternalsSymbol]) {
9292
const totalBytes = request[bodyInternalsSymbol].size;
9393
// Set Content-Length if totalBytes is a number (that is not NaN)
9494
if (typeof totalBytes === 'number' && !Number.isNaN(totalBytes)) {

0 commit comments

Comments
 (0)