diff --git a/src/renderer/src/context/cloud-sync/cloud-sync.context.tsx b/src/renderer/src/context/cloud-sync/cloud-sync.context.tsx index 9581e512..5671ca56 100644 --- a/src/renderer/src/context/cloud-sync/cloud-sync.context.tsx +++ b/src/renderer/src/context/cloud-sync/cloud-sync.context.tsx @@ -169,7 +169,6 @@ export function CloudSyncContextProvider({ setShowCloudSyncModal(false); setRestoringBackup(false); setUploadingBackup(false); - setLoadingPreview(false); }, [objectId, shop]); const backupState = useMemo(() => { diff --git a/src/renderer/src/pages/game-details/cloud-sync-files-modal/cloud-sync-files-modal.tsx b/src/renderer/src/pages/game-details/cloud-sync-files-modal/cloud-sync-files-modal.tsx index a380ddbb..38f20273 100644 --- a/src/renderer/src/pages/game-details/cloud-sync-files-modal/cloud-sync-files-modal.tsx +++ b/src/renderer/src/pages/game-details/cloud-sync-files-modal/cloud-sync-files-modal.tsx @@ -46,7 +46,7 @@ export function CloudSyncFilesModal({ } setValue("customBackupPath", backupPreview?.customBackupPath ?? null); - }, [visible, backupPreview]); + }, [visible, setValue, backupPreview]); const files = useMemo(() => { if (!backupPreview) { @@ -75,7 +75,7 @@ export function CloudSyncFilesModal({ showSuccessToast("custom_backup_location_set"); getGameBackupPreview(); } - }, [objectId, showSuccessToast, getGameBackupPreview]); + }, [objectId, setValue, shop, showSuccessToast, getGameBackupPreview]); const handleFileMappingMethodClick = useCallback( (mappingOption: FileMappingMethod) => { @@ -86,7 +86,7 @@ export function CloudSyncFilesModal({ setSelectedFileMappingMethod(mappingOption); }, - [] + [getGameBackupPreview, shop, objectId] ); return (