Opal-Estate-Pro/node_modules/error/option.js

20 lines
377 B
JavaScript
Raw Normal View History

2019-09-13 06:27:52 +02:00
module.exports = OptionError
function OptionError(message, options) {
var result = new Error()
Object.defineProperty(result, "type", {
value: result.type,
enumerable: true,
writable: true,
configurable: true
})
result.option = options || null
result.message = message
result.type = "OptionError"
return result
}