mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-02-10 23:36:14 -05:00
12 lines
324 B
JavaScript
12 lines
324 B
JavaScript
|
function IncorrectUsage(message, context) {
|
||
|
this.name = 'IncorrectUsage';
|
||
|
this.stack = new Error().stack;
|
||
|
this.statusCode = 400;
|
||
|
this.errorType = this.name;
|
||
|
this.message = message;
|
||
|
this.context = context;
|
||
|
}
|
||
|
|
||
|
IncorrectUsage.prototype = Object.create(Error.prototype);
|
||
|
module.exports = IncorrectUsage;
|