mirror of
https://github.com/hydralauncher/hydra.git
synced 2025-03-09 15:40:26 +00:00
feat: add success and error toast
This commit is contained in:
parent
b68fe300ba
commit
ef3bf98903
4 changed files with 12 additions and 4 deletions
|
|
@ -149,8 +149,11 @@ export function GameOptionsModal({
|
|||
setIsDeletingAchievements(true);
|
||||
try {
|
||||
await window.electron.resetGameAchievements(game.id);
|
||||
} finally {
|
||||
await updateGame();
|
||||
showSuccessToast(t("reset_achievements_success"));
|
||||
} catch (error) {
|
||||
showErrorToast(t("reset_achievements_error"));
|
||||
} finally {
|
||||
setIsDeletingAchievements(false);
|
||||
}
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue