Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- module.exports = function CustomError(message) {
- this.name = this.constructor.name
- this.message = message
- Error.captureStackTrace(this, this.constructor)
- }
- module.exports.prototype.inspect = function () {
- return this.stack
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement