UNPKG

express-decorated-router

Version:

Define Express routes using TypeScript decorators

20 lines (19 loc) 617 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); /** * Thrown when an input of a @Parent decoration has not been decorated with @Controller */ class ParentControllerError extends Error { /** * @internal * @hidden * @param child Child controller * @param parent Parent controller */ constructor(child, parent) { super(`Parent controller ${parent.name} as specified by child controller ${child.name} has not been registered`); this.child = child; this.parent = parent; } } exports.ParentControllerError = ParentControllerError;