1
0
Fork 0

Fix UndocumentedBody

This commit is contained in:
Alan Plum 2015-12-08 20:16:15 +01:00
parent ac291a9a17
commit 8cd34bc586
1 changed files with 2 additions and 3 deletions

View File

@ -363,7 +363,6 @@ class Controller {
this.allRoutes, this.models, newRoute, route, this.rootElement, constraints, this.extensions this.allRoutes, this.models, newRoute, route, this.rootElement, constraints, this.extensions
); );
var summary; var summary;
var undocumentedBody;
this.routingInfo.routes.push(newRoute); this.routingInfo.routes.push(newRoute);
@ -379,10 +378,10 @@ class Controller {
if (method === 'post' || method === 'put' || method === 'patch') { if (method === 'post' || method === 'put' || method === 'patch') {
const Model = require('@arangodb/foxx').Model; const Model = require('@arangodb/foxx').Model;
undocumentedBody = class UndocumentedBody extends Model {}; let UndocumentedBody = Model.extend({});
requestContext.bodyParam('undocumented body', { requestContext.bodyParam('undocumented body', {
description: 'Undocumented body param', description: 'Undocumented body param',
type: undocumentedBody, type: UndocumentedBody,
allowInvalid: true allowInvalid: true
}); });
} }