fix login switch bug

This commit is contained in:
tomasz.kasprowicz 2021-01-15 20:40:04 +01:00
parent 9dc3ada60e
commit d4f669197a

View File

@ -35,9 +35,15 @@ const Login = (props: any) => {
signUp
? props.auth(email, password, true)
: props.auth(email, password, false);
clearForm();
}
};
const clearForm = () => {
setEmail("");
setPassword("");
}
return (
<StyledForm>
<form onSubmit={authorizationHandler}>