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

better-custom-error

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

better-custom-error - npm Package Compare versions

Comparing version 4.0.2 to 4.0.3

4

CHANGELOG.md

@@ -6,2 +6,6 @@ All notable changes to this project will be documented in this file.

## [4.0.3] - 2021-05-27
### Fixed
- typings issue when instanceof with custom error would narrow to Error
## [4.0.2] - 2021-05-27

@@ -8,0 +12,0 @@ ### Fixed

3

dist/types.d.ts

@@ -9,4 +9,5 @@ declare type Names = (string | Names)[];

declare type Arg = Error | CustomError | string | Data | undefined | null;
interface CustomErrorConstructor extends ErrorConstructor, CustomError {
interface CustomErrorConstructor extends CustomError {
new (arg1?: Arg, arg2?: Arg, arg3?: Arg): CustomError;
(arg1?: Arg, arg2?: Arg, arg3?: Arg): CustomError;
}

@@ -13,0 +14,0 @@ interface Options {

@@ -9,4 +9,5 @@ declare type Names = (string | Names)[];

declare type Arg = Error | CustomError | string | Data | undefined | null;
interface CustomErrorConstructor extends ErrorConstructor, CustomError {
interface CustomErrorConstructor extends CustomError {
new (arg1?: Arg, arg2?: Arg, arg3?: Arg): CustomError;
(arg1?: Arg, arg2?: Arg, arg3?: Arg): CustomError;
}

@@ -13,0 +14,0 @@ interface Options {

{
"name": "better-custom-error",
"version": "4.0.2",
"version": "4.0.3",
"repository": "git@github.com:dzek69/better-custom-error.git",

@@ -5,0 +5,0 @@ "author": "Jacek Nowacki @dzek69 <git-public@dzek.eu>",

@@ -107,3 +107,2 @@ import {

// @ts-expect-error overriding prototype, sorry TS
CustomError.prototype = new ParentError();

@@ -110,0 +109,0 @@ return CustomError;

@@ -20,4 +20,5 @@ type Names = (string | Names)[];

interface CustomErrorConstructor extends ErrorConstructor, CustomError {
interface CustomErrorConstructor extends CustomError {
new(arg1?: Arg, arg2?: Arg, arg3?: Arg): CustomError;
(arg1?: Arg, arg2?: Arg, arg3?: Arg): CustomError;
}

@@ -24,0 +25,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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