From 2d218a14565c53e47d42b6da6f6b71cc5d5a20e6 Mon Sep 17 00:00:00 2001 From: Milton Boos Junior Date: Wed, 3 May 2023 15:19:44 +0100 Subject: [PATCH] fix: query function without return (#1459) --- frontend/src/hooks/auth/useSignUp.tsx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/frontend/src/hooks/auth/useSignUp.tsx b/frontend/src/hooks/auth/useSignUp.tsx index 032ca017c..39fc7cafc 100644 --- a/frontend/src/hooks/auth/useSignUp.tsx +++ b/frontend/src/hooks/auth/useSignUp.tsx @@ -21,11 +21,10 @@ const useSignUp = (emailName: EmailNameType, { onSuccess, onError }: UseSignUpCa return useQuery( ['checkUserExists', emailName.email], - () => { + () => NEXT_PUBLIC_ENABLE_AZURE ? checkUserExistsAD(emailName.email) - : checkUserExists(emailName.email); - }, + : checkUserExists(emailName.email), { enabled: !!emailName.email && !emailName.goback, refetchOnMount: false,