UNPKG

libmodulor

Version:

A TypeScript library to create platform-agnostic applications

10 lines (9 loc) 295 B
import { CustomError } from './CustomError.js'; export class ForbiddenError extends CustomError { httpStatus = 403; constructor(message) { super(message ?? 'Forbidden'); this.name = 'ForbiddenError'; Object.setPrototypeOf(this, ForbiddenError.prototype); } }