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

avow

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

avow - npm Package Compare versions

Comparing version 3.0.1 to 3.0.2

17

index.js

@@ -9,3 +9,18 @@ 'use strict'

catch (e) {
throw e.message ? e.message : e
/**
* Node.js's assert does not allow passing of Error Objects any more
*
* See: https://git.io/vQcv7
* As of Node 8, when `assert` fails, it throws a new AssertionError.
* Thus, if you pass an Error object to a call to `assert` it will ignore
* it.
*
* In order to throw custom errors, we refer to the original
* arguments passed into avow.
*
* This will also work for Node 7 and under.
*/
const lastArg = args[args.length - 1]
if (lastArg instanceof Error) throw lastArg
throw e
}

@@ -12,0 +27,0 @@ }

2

package.json
{
"name": "avow",
"version": "3.0.1",
"version": "3.0.2",
"description": "Proxy for assert that accepts custom Errors",

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

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