fix(editor): Make submit in ChangePasswordView work again (#11227)

This commit is contained in:
कारतोफ्फेलस्क्रिप्ट™ 2024-10-11 18:26:43 +02:00 committed by Ricardo Espinoza
parent ce67d8a78b
commit 4aa135912c
No known key found for this signature in database

View file

@ -47,12 +47,7 @@ const getMfaEnabled = () => {
return router.currentRoute.value.query.mfaEnabled === 'true' ? true : false;
};
const isFormWithMFAToken = (values: { [key: string]: string }): values is { mfaToken: string } => {
return 'mfaToken' in values;
};
const onSubmit = async (values: { [key: string]: string }) => {
if (!isFormWithMFAToken(values)) return;
try {
loading.value = true;
const token = getResetToken();