diff --git a/js/apps/system/aardvark/templates/controller.js.tmpl b/js/apps/system/aardvark/templates/controller.js.tmpl index 8d701d0a5d..263d9056a2 100644 --- a/js/apps/system/aardvark/templates/controller.js.tmpl +++ b/js/apps/system/aardvark/templates/controller.js.tmpl @@ -31,7 +31,7 @@ */ controller.post('/<%= basePath %>', function (req, res) { var <%= modelInstance %> = req.params('<%= modelInstance %>'); - res.json(<%= repositoryInstance %>.save(todo).forClient()); + res.json(<%= repositoryInstance %>.save(<%= modelInstance %>).forClient()); }).bodyParam('<%= modelInstance %>', 'The <%= model %> you want to create', <%= model %>); /** Updates a <%= model %>