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

wonderful-fetch

Package Overview
Dependencies
Maintainers
1
Versions
32
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

wonderful-fetch - npm Package Compare versions

Comparing version 1.1.0 to 1.1.1

18

dist/index.js

@@ -23,3 +23,3 @@ (function (root, factory) {

var SOURCE = 'library';
var VERSION = '1.1.0';
var VERSION = '1.1.1';

@@ -112,5 +112,5 @@ function WonderfulFetch(url, options) {

function _output(res, r) {
function _output(res, result) {
var headers = {};
var isError = r instanceof Error;
var isError = result instanceof Error;

@@ -131,3 +131,3 @@ // Iterate over headers and add them to the object

Object.keys(headers[key]).forEach(function (k) {
r[k] = headers[key][k];
result[k] = headers[key][k];
})

@@ -143,3 +143,3 @@ } catch (e) {

if (isError || options.output === 'body') {
return r;
return result;
} else {

@@ -149,3 +149,3 @@ return {

headers: headers,
body: r,
body: result,
}

@@ -155,5 +155,5 @@ }

function _resolve(res, r) {
function _resolve(res, result) {
clearTimeout(timeoutHolder);
return resolve(_output(res, r));
return resolve(_output(res, result));
}

@@ -247,3 +247,3 @@

.catch(function (e) {
return _reject(res, e)
return _reject(undefined, e)
})

@@ -250,0 +250,0 @@ }, ms);

{
"name": "wonderful-fetch",
"version": "1.1.0",
"version": "1.1.1",
"description": "A wrapper around fetch.",

@@ -36,2 +36,2 @@ "main": "./dist/index.js",

}
}
}
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