mirror of
https://github.com/hydralauncher/hydra.git
synced 2025-03-09 15:40:26 +00:00
adjustments
This commit is contained in:
parent
9af6b10f67
commit
86798bb352
4 changed files with 20 additions and 12 deletions
|
|
@ -58,7 +58,8 @@ export function HeroPanelActions() {
|
|||
setToggleLibraryGameDisabled(true);
|
||||
|
||||
try {
|
||||
await window.electron.addGameToFavorites(shop, objectId!);
|
||||
if (!objectId) throw new Error("objectId is required");
|
||||
await window.electron.addGameToFavorites(shop, objectId);
|
||||
updateLibrary();
|
||||
updateGame();
|
||||
} finally {
|
||||
|
|
@ -70,7 +71,8 @@ export function HeroPanelActions() {
|
|||
setToggleLibraryGameDisabled(true);
|
||||
|
||||
try {
|
||||
await window.electron.removeGameFromFavorites(shop, objectId!);
|
||||
if (!objectId) throw new Error("objectId is required");
|
||||
await window.electron.removeGameFromFavorites(shop, objectId);
|
||||
updateLibrary();
|
||||
updateGame();
|
||||
} finally {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue