Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@ejnshtein/smol-request

Package Overview
Dependencies
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ejnshtein/smol-request - npm Package Compare versions

Comparing version 1.0.10 to 1.0.11

2

package.json
{
"name": "@ejnshtein/smol-request",
"version": "1.0.10",
"version": "1.0.11",
"description": "Tiny http/https request wrapper for Node.js using ESM (13.5 and newer)",

@@ -5,0 +5,0 @@ "main": "Request.js",

@@ -45,2 +45,3 @@ // docs: https://nodejs.org/dist/latest-v10.x/docs/api/https.html#https_https_request_url_options_callback

const client = url.startsWith('https') ? https : http
let resolved = false
const result = {

@@ -65,2 +66,5 @@ data: null,

function onClose () {
if (resolved) {
return
}
switch (requestOptions.responseType) {

@@ -95,2 +99,3 @@ case 'buffer': {

if (requestOptions.responseType === 'headers') {
resolved = true
return resolve(result)

@@ -103,2 +108,3 @@ }

result.data = stream
resolved = true
return resolve(result)

@@ -105,0 +111,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc