feat: add error toast

This commit is contained in:
Zamitto 2024-09-13 17:30:18 -03:00
parent e8515e1990
commit a03ac26b80
4 changed files with 7 additions and 3 deletions

View file

@ -60,6 +60,7 @@ export const UserEditProfile = ({
const { imagePath } = await window.electron
.processProfileImage(filePaths[0])
.catch(() => {
showErrorToast(t("image_process_failure"));
return { imagePath: null };
})
.finally(() => setIsLoadingImage(false));