fix: updating password ui bug #7775 (#7815)

* fix: updating password ui bug #7775

* fix: type error
This commit is contained in:
Joe
2023-03-27 20:58:46 +02:00
committed by GitHub
parent d5c3d9d967
commit 78da57055e
@@ -338,6 +338,11 @@ const PlainForm = <T extends FieldValues>(props: FormProps<T>, ref: Ref<HTMLForm
onSubmit={(event) => {
event.preventDefault();
event.stopPropagation();
if (form.formState?.errors?.apiError) {
form.clearErrors("root");
}
form
.handleSubmit(handleSubmit)(event)
.catch((err) => {