mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-16 21:00:31 +00:00
refactor: currencies service.
refactor: exchange rates service.
This commit is contained in:
@@ -22,8 +22,8 @@ export default class InviteUsersController extends BaseController {
|
||||
const router = Router();
|
||||
|
||||
router.post('/send', [
|
||||
body('email').exists().trim().escape(),
|
||||
],
|
||||
body('email').exists().trim().escape(),
|
||||
],
|
||||
this.validationResult,
|
||||
asyncMiddleware(this.sendInvite.bind(this)),
|
||||
);
|
||||
@@ -117,9 +117,7 @@ export default class InviteUsersController extends BaseController {
|
||||
message: 'User invite has been accepted successfully.',
|
||||
});
|
||||
} catch (error) {
|
||||
|
||||
if (error instanceof ServiceError) {
|
||||
|
||||
if (error.errorType === 'phone_number_exists') {
|
||||
return res.status(400).send({
|
||||
errors: [{ type: 'PHONE_NUMBER.EXISTS' }],
|
||||
|
||||
Reference in New Issue
Block a user