0
0
Fork 0

fix: proposal to avoid notify error

This commit is contained in:
Javier Segarra 2024-07-10 15:03:25 +02:00
parent 36fc988df2
commit 3f1c0b95fa
4 changed files with 4 additions and 4 deletions

View File

@ -92,7 +92,7 @@ const onSubmit = async () => {
notify('globals.dataSaved', 'positive'); notify('globals.dataSaved', 'positive');
unpaidClient.value = true; unpaidClient.value = true;
} catch (error) { } catch (error) {
notify('errors.create', 'negative'); notify('errors.writeRequest', 'negative');
} finally { } finally {
isLoading.value = false; isLoading.value = false;
} }

View File

@ -70,7 +70,7 @@ const onSubmit = async () => {
notify('globals.dataSaved', 'positive'); notify('globals.dataSaved', 'positive');
if (usersPreviewRef.value) usersPreviewRef.value.fetch(); if (usersPreviewRef.value) usersPreviewRef.value.fetch();
} catch (error) { } catch (error) {
notify('errors.create', 'negative'); notify('errors.writeRequest', 'negative');
} finally { } finally {
isLoading.value = false; isLoading.value = false;
} }

View File

@ -48,7 +48,7 @@ const onSubmit = async () => {
await axios.patch(`Clients/${$props.id}/setPassword`, payload); await axios.patch(`Clients/${$props.id}/setPassword`, payload);
await $props.promise(); await $props.promise();
} catch (error) { } catch (error) {
notify('errors.create', 'negative'); notify('errors.writeRequest', 'negative');
} finally { } finally {
isLoading.value = false; isLoading.value = false;
if (closeButton.value) closeButton.value.click(); if (closeButton.value) closeButton.value.click();

View File

@ -150,7 +150,7 @@ const onSubmit = async () => {
notify('globals.dataSaved', 'positive'); notify('globals.dataSaved', 'positive');
onDataSaved(data); onDataSaved(data);
} catch (error) { } catch (error) {
notify('errors.create', 'negative'); notify('errors.writeRequest', 'negative');
} finally { } finally {
isLoading.value = false; isLoading.value = false;
} }