fix(one-to-many): raw parameters are removed
This commit is contained in:
parent
11291f0e08
commit
097a9adcf3
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "hapi-sequelize-crud",
|
"name": "hapi-sequelize-crud",
|
||||||
"version": "2.0.0",
|
"version": "2.0.1",
|
||||||
"description": "Hapi plugin that automatically generates RESTful API for CRUD",
|
"description": "Hapi plugin that automatically generates RESTful API for CRUD",
|
||||||
"main": "build/index.js",
|
"main": "build/index.js",
|
||||||
"config": {
|
"config": {
|
||||||
|
@ -152,7 +152,9 @@ export const destroy = (server, a, b, names) => {
|
|||||||
const where = parseWhere(request);
|
const where = parseWhere(request);
|
||||||
|
|
||||||
const base = await a.findOne({
|
const base = await a.findOne({
|
||||||
where: request.params.aid
|
where: {
|
||||||
|
id: request.params.aid
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
const method = getMethod(base, names.b);
|
const method = getMethod(base, names.b);
|
||||||
|
Loading…
Reference in New Issue
Block a user