mirror of
https://github.com/hydralauncher/hydra.git
synced 2026-01-27 21:01:02 +00:00
fix: remove unnecessary useEffect
This commit is contained in:
@@ -139,12 +139,6 @@ export function DownloadSettingsModal({
|
|||||||
userPreferences?.torBoxApiToken,
|
userPreferences?.torBoxApiToken,
|
||||||
]);
|
]);
|
||||||
|
|
||||||
useEffect(() => {
|
|
||||||
if (userPreferences?.extractFilesByDefault === undefined) {
|
|
||||||
window.electron.updateUserPreferences({ extractFilesByDefault: true });
|
|
||||||
}
|
|
||||||
}, [userPreferences?.extractFilesByDefault]);
|
|
||||||
|
|
||||||
const handleChooseDownloadsPath = async () => {
|
const handleChooseDownloadsPath = async () => {
|
||||||
const { filePaths } = await window.electron.showOpenDialog({
|
const { filePaths } = await window.electron.showOpenDialog({
|
||||||
defaultPath: selectedPath,
|
defaultPath: selectedPath,
|
||||||
|
|||||||
@@ -88,7 +88,7 @@ export interface UserPreferences {
|
|||||||
achievementNotificationsEnabled?: boolean;
|
achievementNotificationsEnabled?: boolean;
|
||||||
friendRequestNotificationsEnabled?: boolean;
|
friendRequestNotificationsEnabled?: boolean;
|
||||||
showDownloadSpeedInMegabytes?: boolean;
|
showDownloadSpeedInMegabytes?: boolean;
|
||||||
extractFilesByDefault?: boolean;
|
extractFilesByDefault?: boolean | undefined;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface ScreenState {
|
export interface ScreenState {
|
||||||
|
|||||||
Reference in New Issue
Block a user