Skip to content

The open alternative to Salesforce, designed for AI.

fix: Requests for new captcha token after a wrong password is entered. (#5614)

Piyush Yadavef64911e4595
diff --git a/packages/twenty-front/src/modules/auth/sign-in-up/hooks/useSignInUp.tsx b/packages/twenty-front/src/modules/auth/sign-in-up/hooks/useSignInUp.tsx
index ba8ddd471c6..24111466a69 100644
--- a/packages/twenty-front/src/modules/auth/sign-in-up/hooks/useSignInUp.tsx
+++ b/packages/twenty-front/src/modules/auth/sign-in-up/hooks/useSignInUp.tsx
@@ -118,6 +118,7 @@ export const useSignInUp = (form: UseFormReturn<Form>) => {
enqueueSnackBar(err?.message, {
variant: SnackBarVariant.Error,
});
+ requestFreshCaptchaToken();
}
},
[
@@ -128,6 +129,7 @@ export const useSignInUp = (form: UseFormReturn<Form>) => {
signUpWithCredentials,
workspaceInviteHash,
enqueueSnackBar,
+ requestFreshCaptchaToken,
],
);