(message)
| 5662 | |
| 5663 | function subError(nameProperty, defaultMessage) { |
| 5664 | function SubError(message) { |
| 5665 | if (!(this instanceof SubError)) return new SubError(message); |
| 5666 | notEnumerableProp(this, "message", |
| 5667 | typeof message === "string" ? message : defaultMessage); |
| 5668 | notEnumerableProp(this, "name", nameProperty); |
| 5669 | if (Error.captureStackTrace) { |
| 5670 | Error.captureStackTrace(this, this.constructor); |
| 5671 | } else { |
| 5672 | Error.call(this); |
| 5673 | } |
| 5674 | } |
| 5675 | inherits(SubError, Error); |
| 5676 | return SubError; |
| 5677 | } |
nothing calls this directly
no test coverage detected