trycatch
trycatch copied to clipboard
Stack trace is lost when Error catched inherits from Error base class
Hi When we use inheritance for error handling, but also for standard error class like ReferenceError etc..., the stack trace is lost. Its because of function isError in formatError.js check is made with Object.prototype.toString.call(err) === '[object Error]' but it should be err instanceof Error; to take inheritance in account Thanks