mirror of
https://github.com/hydralauncher/hydra.git
synced 2026-01-18 16:53:57 +00:00
Merge branch 'main' into feat/reviews-and-commenting
This commit is contained in:
@@ -253,6 +253,7 @@
|
||||
"uploading_backup": "Uploading backup…",
|
||||
"no_backups": "You haven't created any backups for this game yet",
|
||||
"backup_uploaded": "Backup uploaded",
|
||||
"backup_failed": "Backup failed",
|
||||
"backup_deleted": "Backup deleted",
|
||||
"backup_restored": "Backup restored",
|
||||
"see_all_achievements": "See all achievements",
|
||||
|
||||
@@ -204,6 +204,7 @@
|
||||
"uploading_backup": "Subiendo copia de seguridad…",
|
||||
"no_backups": "No has creado ninguna copia de seguridad para este juego todavía",
|
||||
"backup_uploaded": "Copia de seguridad subida",
|
||||
"backup_failed": "Copia de seguridad fallida",
|
||||
"backup_deleted": "Copia de seguridad eliminada",
|
||||
"backup_restored": "Copia de seguridad restaurada",
|
||||
"see_all_achievements": "Ver todos los logros",
|
||||
|
||||
@@ -142,6 +142,7 @@
|
||||
"uploading_backup": "A criar backup…",
|
||||
"no_backups": "Ainda não fizeste nenhum backup deste jogo",
|
||||
"backup_uploaded": "Backup criado",
|
||||
"backup_failed": "Falha ao criar backup",
|
||||
"backup_deleted": "Backup apagado",
|
||||
"backup_restored": "Backup restaurado",
|
||||
"see_all_achievements": "Ver todas as conquistas",
|
||||
|
||||
@@ -80,7 +80,7 @@ export class CloudSync {
|
||||
try {
|
||||
await fs.promises.rm(backupPath, { recursive: true });
|
||||
} catch (error) {
|
||||
logger.error("Failed to remove backup path", error);
|
||||
logger.error("Failed to remove backup path", { backupPath, error });
|
||||
}
|
||||
}
|
||||
|
||||
@@ -163,7 +163,7 @@ export class CloudSync {
|
||||
try {
|
||||
await fs.promises.unlink(bundleLocation);
|
||||
} catch (error) {
|
||||
logger.error("Failed to remove tar file", error);
|
||||
logger.error("Failed to remove tar file", { bundleLocation, error });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,7 +22,8 @@ export const mergeWithRemoteGames = async () => {
|
||||
const updatedLastTimePlayed =
|
||||
localGame.lastTimePlayed == null ||
|
||||
(game.lastTimePlayed &&
|
||||
new Date(game.lastTimePlayed) > localGame.lastTimePlayed)
|
||||
new Date(game.lastTimePlayed) >
|
||||
new Date(localGame.lastTimePlayed))
|
||||
? game.lastTimePlayed
|
||||
: localGame.lastTimePlayed;
|
||||
|
||||
|
||||
@@ -76,7 +76,11 @@ export const getSteamAppDetails = async (
|
||||
return null;
|
||||
})
|
||||
.catch((err) => {
|
||||
logger.error(err, { method: "getSteamAppDetails" });
|
||||
logger.error("Error on getSteamAppDetails", {
|
||||
message: err?.message,
|
||||
code: err?.code,
|
||||
name: err?.name,
|
||||
});
|
||||
return null;
|
||||
});
|
||||
};
|
||||
|
||||
@@ -87,7 +87,7 @@ export function CloudSyncContextProvider({
|
||||
const [loadingPreview, setLoadingPreview] = useState(false);
|
||||
const [freezingArtifact, setFreezingArtifact] = useState(false);
|
||||
|
||||
const { showSuccessToast } = useToast();
|
||||
const { showSuccessToast, showErrorToast } = useToast();
|
||||
|
||||
const downloadGameArtifact = useCallback(
|
||||
async (gameArtifactId: string) => {
|
||||
@@ -122,9 +122,15 @@ export function CloudSyncContextProvider({
|
||||
const uploadSaveGame = useCallback(
|
||||
async (downloadOptionTitle: string | null) => {
|
||||
setUploadingBackup(true);
|
||||
window.electron.uploadSaveGame(objectId, shop, downloadOptionTitle);
|
||||
window.electron
|
||||
.uploadSaveGame(objectId, shop, downloadOptionTitle)
|
||||
.catch((err) => {
|
||||
setUploadingBackup(false);
|
||||
logger.error("Failed to upload save game", { objectId, shop, err });
|
||||
showErrorToast(t("backup_failed"));
|
||||
});
|
||||
},
|
||||
[objectId, shop]
|
||||
[objectId, shop, t, showErrorToast]
|
||||
);
|
||||
|
||||
const toggleArtifactFreeze = useCallback(
|
||||
|
||||
Reference in New Issue
Block a user