Browse Source

fix: on delete fail, return error instead of 200 OK

Signed-off-by: Raju Udava <86527202+dstala@users.noreply.github.com>
pull/5881/head
Raju Udava 1 year ago
parent
commit
379f82b5e6
  1. 2
      packages/nocodb/src/services/datas.service.ts

2
packages/nocodb/src/services/datas.service.ts

@ -106,7 +106,7 @@ export class DatasService {
// todo: Should have error http status code
const message = await baseModel.hasLTARData(param.rowId, model);
if (message.length) {
return { message };
NcError.badRequest(message);
}
return await baseModel.delByPk(param.rowId, null, param.cookie);
}

Loading…
Cancel
Save