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

nest

Package Overview
Dependencies
Maintainers
0
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nest - npm Package Compare versions

Comparing version 0.0.3 to 0.0.4

deps/querystring/index.js

20

index.js

@@ -98,10 +98,7 @@ // The MIT License

if ('object' === typeof options.params) {
if (this.params) {
mixin(options.params, this.params);
}
options.path += '?' + querystring.stringify(options.params);
} else {
options.path += '?' + options.params;
if (this.params) {
mixin(options.params, this.params);
}
options.path += '?' + querystring.stringify(options.params);
}

@@ -112,6 +109,5 @@

if ('json' === options.type) {
options.headers['Content-Type'] = 'application/json';
options.body = JSON.stringify(options.body);
} else {
options.headers['Content-Type'] = 'application/x-www-form-urlencoded';
options.type = 'form';
options.body = querystring.stringify(options.body);

@@ -123,2 +119,8 @@ }

options.headers['Content-Length'] = Buffer.byteLength(options.body);
if ('json' === options.type) {
options.headers['Content-Type'] = 'application/json';
} else if ('form' === options.type) {
options.headers['Content-Type'] = 'application/x-www-form-urlencoded';
}
} else if ('DELETE' === method ||

@@ -125,0 +127,0 @@ 'PUT' === method ||

{
"name": "nest",
"version": "0.0.3",
"version": "0.0.4",
"description": "A Node HTTP client aimed at REST API's.",

@@ -5,0 +5,0 @@ "repository": {

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