Browse Source

fix(nocodb): projectUserService.userInvite

pull/5269/head
Wing-Kam Wong 2 years ago
parent
commit
7c4a2b7f9a
  1. 25
      packages/nocodb/src/lib/controllers/projectUser.ctl.ts

25
packages/nocodb/src/lib/controllers/projectUser.ctl.ts

@ -13,14 +13,13 @@ async function userList(req, res) {
}
async function userInvite(req, res): Promise<any> {
await projectUserService.userInvite({
projectId: req.params.projectId,
projectUser: req.body,
req,
})
res.json({
msg: 'The user has been invited successfully',
});
res.json(
await projectUserService.userInvite({
projectId: req.params.projectId,
projectUser: req.body,
req,
})
);
}
async function projectUserUpdate(req, res): Promise<any> {
@ -29,7 +28,7 @@ async function projectUserUpdate(req, res): Promise<any> {
projectId: req.params.projectId,
userId: req.params.userId,
req,
})
});
res.json({
msg: 'The user has been updated successfully',
});
@ -52,12 +51,10 @@ async function projectUserInviteResend(req, res): Promise<any> {
userId: req.params.userId,
projectUser: req.body,
req,
})
;
});
res.json({
msg: 'The invitation has been sent to the user'
})
msg: 'The invitation has been sent to the user',
});
}
const router = Router({ mergeParams: true });

Loading…
Cancel
Save