From 593171bb795c015cbd344fb8a6e1312e9b96042d Mon Sep 17 00:00:00 2001 From: Ayush Kumar <2580ayush2580@gmail.com> Date: Sat, 23 Jan 2021 15:31:59 +0530 Subject: [PATCH] Continuing without email' dialog bug fixes --- .../views/dialogs/RegistrationEmailPromptDialog.tsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/views/dialogs/RegistrationEmailPromptDialog.tsx b/src/components/views/dialogs/RegistrationEmailPromptDialog.tsx index b7cc81c113..3f3ad215a5 100644 --- a/src/components/views/dialogs/RegistrationEmailPromptDialog.tsx +++ b/src/components/views/dialogs/RegistrationEmailPromptDialog.tsx @@ -44,7 +44,8 @@ const RegistrationEmailPromptDialog: React.FC = ({onFinished}) => { const [email, setEmail] = useState(""); const fieldRef = useRef(); - const onSubmit = async () => { + const onSubmit = async (e) => { + e.preventDefault(); if (email) { const valid = await fieldRef.current.validate({ allowEmpty: false }); @@ -73,6 +74,7 @@ const RegistrationEmailPromptDialog: React.FC = ({onFinished}) => {