Socket
Socket
Sign inDemoInstall

req-then

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

req-then - npm Package Compare versions

Comparing version 0.2.3 to 0.2.4

3

lib/req-then.js

@@ -55,3 +55,3 @@ 'use strict'

var reqOptions = urlUtils.parse(url)
reqOptions.method = options.method || 'GET'
reqOptions.method = options.method || (options.data ? 'POST' : 'GET')
reqOptions.headers = options.headers || options.header

@@ -79,3 +79,2 @@

var req = transport.request(reqOptions, function (res) {
var data = Buffer(0)

@@ -82,0 +81,0 @@ res.on('data', function resOnData (chunk) {

{
"name": "req-then",
"author": "Lloyd Brookes <75pound@gmail.com>",
"version": "0.2.3",
"version": "0.2.4",
"description": "Simple http(s) request function, returning a promise. ",

@@ -6,0 +6,0 @@ "repository": "https://github.com/75lb/req-then",

'use strict'
var http = require('http')
var util = require('util')

@@ -5,0 +4,0 @@ /* simple echo server.. useful for testing POST requests.. */

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