Socket
Socket
Sign inDemoInstall

loud-rejection

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

loud-rejection - npm Package Compare versions

Comparing version 1.2.0 to 1.2.1

7

api.js
'use strict';
var arrayFindIndex = require('array-find-index');

@@ -13,5 +14,5 @@ // WARNING: This undocumented API is subject to change.

process.on('rejectionHandled', function (p) {
var index = unhandledRejections.reduce(function (result, item, idx) {
return (item.promise === p ? idx : result);
}, -1);
var index = arrayFindIndex(unhandledRejections, function (x) {
return x.promise === p;
});

@@ -18,0 +19,0 @@ unhandledRejections.splice(index, 1);

@@ -18,3 +18,2 @@ 'use strict';

if (installed) {
console.trace('WARN: loud rejection called more than once');
return;

@@ -21,0 +20,0 @@ }

{
"name": "loud-rejection",
"version": "1.2.0",
"version": "1.2.1",
"description": "Make unhandled promise rejections fail loudly instead of the default silent fail",

@@ -41,2 +41,3 @@ "license": "MIT",

"dependencies": {
"array-find-index": "^1.0.0",
"signal-exit": "^2.1.2"

@@ -50,15 +51,8 @@ },

"get-stream": "^1.0.0",
"nyc": "^3.2.2",
"nyc": "^5.0.1",
"xo": "*"
},
"xo": {
"ignores": [
"test.js"
]
},
"config": {
"nyc": {
"exclude": [
"node_modules",
"test.js",
"fixture.js"

@@ -65,0 +59,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