diff --git a/packages/builder/src/pages/builder/portal/manage/users/index.svelte b/packages/builder/src/pages/builder/portal/manage/users/index.svelte index e7d8497b46..ea61e3fcf3 100644 --- a/packages/builder/src/pages/builder/portal/manage/users/index.svelte +++ b/packages/builder/src/pages/builder/portal/manage/users/index.svelte @@ -144,10 +144,10 @@ userData = await removingDuplicities({ groups, users }) if (!userData.users.length) return - return createUser() + return createUsers() } - async function createUser() { + async function createUsers() { try { createUsersResponse = await users.create( await removingDuplicities(userData) @@ -164,7 +164,7 @@ if (onboardingType === "emailOnboarding") { createUserFlow() } else { - await createUser() + await createUsers() } } diff --git a/packages/worker/src/api/routes/global/tests/users.spec.ts b/packages/worker/src/api/routes/global/tests/users.spec.ts index a4e5591844..7762c2e7e2 100644 --- a/packages/worker/src/api/routes/global/tests/users.spec.ts +++ b/packages/worker/src/api/routes/global/tests/users.spec.ts @@ -38,7 +38,7 @@ describe("/api/global/users", () => { expect(events.user.invited).toBeCalledTimes(1) }) - it("should be able to generate an invitation for existing user", async () => { + it("should not be able to generate an invitation for existing user", async () => { const { code, res } = await api.users.sendUserInvite( sendMailMock, config.defaultUser!.email,