UNPKG

@opra/common

Version:
24 lines (23 loc) 722 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.UnprocessableEntityError = void 0; const opra_http_error_js_1 = require("../opra-http-error.js"); /** * 422 Unprocessable Entity * The request was well-formed but was unable to be followed due to semantic errors. */ class UnprocessableEntityError extends opra_http_error_js_1.OpraHttpError { constructor() { super(...arguments); this.status = 422; } init(issue) { super.init({ message: 'Unprocessable entity', severity: 'error', code: 'UNPROCESSABLE_ENTITY', ...issue, }); } } exports.UnprocessableEntityError = UnprocessableEntityError;