UNPKG

zents

Version:

ZenTS is a Node.js & TypeScript MVC-Framework for building rich web applications, released as free and open-source software under the MIT License. It is designed for building web applications with modern tools and design patterns.

23 lines 822 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.BodyContextAction = void 0; const AbstractAction_1 = require("./AbstractAction"); const types_1 = require("../../types"); class BodyContextAction extends AbstractAction_1.AbstractAction { constructor(injector, context) { super(injector); this.context = context; } run(instance, method) { if (!Reflect.hasMetadata(types_1.REFLECT_METADATA.CONTEXT_BODY, instance, method)) { return; } const metadata = Reflect.getMetadata(types_1.REFLECT_METADATA.CONTEXT_BODY, instance, method); return { index: metadata, value: this.context.body, }; } } exports.BodyContextAction = BodyContextAction; //# sourceMappingURL=BodyContextAction.js.map