@smithy/node-http-handler
Advanced tools
@@ -165,4 +165,11 @@ 'use strict'; | ||
| if (body) { | ||
| if (Buffer.isBuffer(body) || typeof body === "string") { | ||
| httpRequest.end(body); | ||
| const isBuffer = Buffer.isBuffer(body); | ||
| const isString = typeof body === "string"; | ||
| if (isBuffer || isString) { | ||
| if (isBuffer && body.byteLength === 0) { | ||
| httpRequest.end(); | ||
| } | ||
| else { | ||
| httpRequest.end(body); | ||
| } | ||
| return; | ||
@@ -169,0 +176,0 @@ } |
@@ -40,4 +40,11 @@ import { Readable } from "stream"; | ||
| if (body) { | ||
| if (Buffer.isBuffer(body) || typeof body === "string") { | ||
| httpRequest.end(body); | ||
| const isBuffer = Buffer.isBuffer(body); | ||
| const isString = typeof body === "string"; | ||
| if (isBuffer || isString) { | ||
| if (isBuffer && body.byteLength === 0) { | ||
| httpRequest.end(); | ||
| } | ||
| else { | ||
| httpRequest.end(body); | ||
| } | ||
| return; | ||
@@ -44,0 +51,0 @@ } |
+1
-1
| { | ||
| "name": "@smithy/node-http-handler", | ||
| "version": "4.4.9", | ||
| "version": "4.4.10", | ||
| "description": "Provides a way to make requests", | ||
@@ -5,0 +5,0 @@ "scripts": { |
Network access
Supply chain riskThis module accesses the network.
Found 3 instances in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 3 instances in 1 package
97716
0.43%2081
0.68%