@speedup/error
Version:
SpeedUP standard error library
36 lines (35 loc) • 1.29 kB
JavaScript
;
/**
* Application error
*/
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
Object.defineProperty(exports, "__esModule", { value: true });
var error_base_1 = require("./error_base");
/**
* Application Error
*/
var ApplicationError = /** @class */ (function (_super) {
__extends(ApplicationError, _super);
function ApplicationError(config) {
var _this = _super.call(this, config) || this;
// set stacktrace
Error.captureStackTrace(_this, ApplicationError);
// Set prototype to make instanceOf enabled
Object.setPrototypeOf(_this, ApplicationError.prototype);
return _this;
}
return ApplicationError;
}(error_base_1.ErrorBase));
exports.ApplicationError = ApplicationError;