https-client
Advanced tools
+1
-1
| { | ||
| "name": "https-client", | ||
| "version": "1.4.4", | ||
| "version": "1.4.5", | ||
| "description": "Simple REST client for `node.js` `https` module. Adds retries and timeout support to `https` module.", | ||
@@ -5,0 +5,0 @@ "author": "Will Tesler", |
@@ -254,2 +254,17 @@ module.exports = class HttpsClient { | ||
| }); | ||
| if (abortSignal) { | ||
| abortSignal.addEventListener('abort', () => { | ||
| req.destroy(); | ||
| const error = new Error('Aborted'); | ||
| error.statusCode = 499; | ||
| resolve(error); | ||
| }, {once: true}); | ||
| } | ||
| if (type === 'POST' || type === 'PUT' || type === 'DELETE') { | ||
| req.write(body); | ||
| } | ||
| req.end(); | ||
| } catch (e) { | ||
@@ -261,17 +276,2 @@ cancelResponseTimeout(); | ||
| } | ||
| if (abortSignal) { | ||
| abortSignal.addEventListener('abort', () => { | ||
| req.destroy(); | ||
| const error = new Error('Aborted'); | ||
| error.statusCode = 499; | ||
| resolve(error); | ||
| }, {once: true}); | ||
| } | ||
| if (type === 'POST' || type === 'PUT' || type === 'DELETE') { | ||
| req.write(body); | ||
| } | ||
| req.end(); | ||
| }); | ||
@@ -278,0 +278,0 @@ |
Network access
Supply chain riskThis module accesses the network.
Found 2 instances in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 2 instances in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
12386
0.19%