diff --git a/studio/components/interfaces/Account/TOTPFactors/AddNewFactorModal.tsx b/studio/components/interfaces/Account/TOTPFactors/AddNewFactorModal.tsx index fa0b563aec1..5eeff45f7e8 100644 --- a/studio/components/interfaces/Account/TOTPFactors/AddNewFactorModal.tsx +++ b/studio/components/interfaces/Account/TOTPFactors/AddNewFactorModal.tsx @@ -23,6 +23,7 @@ const AddNewFactorModal = ({ visible, onClose }: AddNewFactorModalProps) => { // reset has to be called because the state is kept between if the process is canceled during // the second step. if (!visible) { + setName(`App ${Math.floor(Math.random() * 1000)}`) reset() } }, [reset, visible]) diff --git a/studio/components/interfaces/SignIn/SignInMfaForm.tsx b/studio/components/interfaces/SignIn/SignInMfaForm.tsx index abce02cdeeb..93f3566cd73 100644 --- a/studio/components/interfaces/SignIn/SignInMfaForm.tsx +++ b/studio/components/interfaces/SignIn/SignInMfaForm.tsx @@ -7,13 +7,13 @@ import { useEffect, useState } from 'react' import { Button, Form, IconLock, Input } from 'ui' import { object, string } from 'yup' +import AlertError from 'components/ui/AlertError' import { GenericSkeletonLoader } from 'components/ui/ShimmeringLoader' import { useMfaChallengeAndVerifyMutation } from 'data/profile/mfa-challenge-and-verify-mutation' import { useMfaListFactorsQuery } from 'data/profile/mfa-list-factors-query' import { useStore } from 'hooks' import { usePushNext } from 'hooks/misc/useAutoAuthRedirect' import { useSignOut } from 'lib/auth' -import AlertError from 'components/ui/AlertError' const signInSchema = object({ code: string().required('MFA Code is required'), @@ -45,8 +45,6 @@ const SignInMfaForm = () => { await router.replace('/sign-in') } - console.log({ isLoadingFactors, factors }) - useEffect(() => { if (isSuccessFactors) { // if the user wanders into this page and he has no MFA setup, send the user to the next screen