Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/server web application menu #3341

Merged
merged 5 commits into from
Nov 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions apps/server-web/src/locales/i18n/bg/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,21 @@
"OPEN_WEB": "Отворете уеб в браузъра",
"SERVER_WINDOW": "Прозорец на сървъра"
},
"MENU_APP": {
"ABOUT": "Относно",
"QUIT": "Изход",
"WINDOW": "Прозорец",
"SUBMENU": {
"SETTING": "Настройки",
"SERVER_WINDOW": "Сървърен прозорец",
"LEARN_MORE": "Научете повече",
"DOC": "Документация",
"SETTING_DEV": "Настройки за разработчици",
"SERVER_DEV": "Сървър за разработчици"
},
"DEV": "Разработчик",
"HELP": "Помощ"
},
"FORM": {
"FIELDS": {
"PORT": "ПРИСТАНИЩЕ",
Expand Down
15 changes: 15 additions & 0 deletions apps/server-web/src/locales/i18n/en/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,21 @@
"OPEN_WEB": "Open Web In Browser",
"SERVER_WINDOW": "Server Window"
},
"MENU_APP": {
"ABOUT": "About",
"QUIT": "Quit",
"WINDOW": "Window",
"SUBMENU": {
"SETTING": "Setting",
"SERVER_WINDOW": "Server Window",
"LEARN_MORE": "Learn More",
"DOC": "Documentation",
"SETTING_DEV": "Setting Dev.",
"SERVER_DEV": "Server Dev."
},
"DEV": "Developer",
"HELP": "Help"
},
Comment on lines +17 to +31
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Consider consolidating duplicate menu translations and standardizing naming patterns.

There appear to be overlapping translations between the existing "MENU" section and the new "MENU_APP" section:

  • "ABOUT" duplicates existing translation
  • "QUIT" duplicates "APP_QUIT"
  • "SERVER_WINDOW" exists in both sections
  • "SETTING" duplicates "APP_SETTING"

Additionally, the naming patterns are inconsistent:

  • The "MENU" section uses prefixes like "APP_" and "SERVER_"
  • The "MENU_APP" section doesn't follow this pattern

Consider consolidating these sections and following a consistent naming pattern:

 "MENU_APP": {
-  "ABOUT": "About",
-  "QUIT": "Quit",
-  "WINDOW": "Window",
+  "APP_ABOUT": "About",
+  "APP_QUIT": "Quit",
+  "APP_WINDOW": "Window",
   "SUBMENU": {
-    "SETTING": "Setting",
-    "SERVER_WINDOW": "Server Window",
+    "APP_SETTING": "Setting",
+    "APP_SERVER_WINDOW": "Server Window",
     "LEARN_MORE": "Learn More",
     "DOC": "Documentation",
-    "SETTING_DEV": "Setting Dev.",
-    "SERVER_DEV": "Server Dev."
+    "DEV_SETTING": "Setting Dev.",
+    "DEV_SERVER": "Server Dev."
   },
   "DEV": "Developer",
   "HELP": "Help"
 }
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
"MENU_APP": {
"ABOUT": "About",
"QUIT": "Quit",
"WINDOW": "Window",
"SUBMENU": {
"SETTING": "Setting",
"SERVER_WINDOW": "Server Window",
"LEARN_MORE": "Learn More",
"DOC": "Documentation",
"SETTING_DEV": "Setting Dev.",
"SERVER_DEV": "Server Dev."
},
"DEV": "Developer",
"HELP": "Help"
},
"MENU_APP": {
"APP_ABOUT": "About",
"APP_QUIT": "Quit",
"APP_WINDOW": "Window",
"SUBMENU": {
"APP_SETTING": "Setting",
"APP_SERVER_WINDOW": "Server Window",
"LEARN_MORE": "Learn More",
"DOC": "Documentation",
"DEV_SETTING": "Setting Dev.",
"DEV_SERVER": "Server Dev."
},
"DEV": "Developer",
"HELP": "Help"
},

Comment on lines +17 to +31
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Consider consolidating duplicate menu translations

There are several duplicate translations between the existing "MENU" section and the new "MENU_APP" section:

  • "About" (MENU.ABOUT/APP_ABOUT vs MENU_APP.ABOUT)
  • "Setting" (MENU.APP_SETTING vs MENU_APP.SUBMENU.SETTING)
  • "Server Window" (MENU.SERVER_WINDOW vs MENU_APP.SUBMENU.SERVER_WINDOW)
  • "Quit" (MENU.APP_QUIT vs MENU_APP.QUIT)

This duplication could lead to maintenance issues if translations need to be updated.

Consider consolidating these translations into a single section or clarifying the distinct purposes of "MENU" vs "MENU_APP" through comments.

"FORM": {
"FIELDS": {
"PORT": "PORT",
Expand Down
40 changes: 23 additions & 17 deletions apps/server-web/src/main/helpers/services/libs/desktop-store.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
import Store from 'electron-store';
import { WebServer } from '../../interfaces';
const store = new Store();
const DEFAULT_CONFIG:any = {
server: {
PORT: 3002,
GAUZY_API_SERVER_URL: 'http://localhost:3000',
NEXT_PUBLIC_GAUZY_API_SERVER_URL: 'http://localhost:3000',
DESKTOP_WEB_SERVER_HOSTNAME: '0.0.0.0'
},
general: {
lang: 'en',
autoUpdate: true,
updateCheckPeriode: '1140'
}
}
Comment on lines +4 to +16
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Improve type safety and configuration management

The DEFAULT_CONFIG constant has several areas for improvement:

  1. Replace 'any' type with a proper interface
  2. Consider moving sensitive configuration to environment variables
  3. Add validation for configuration values
  4. Add documentation for each configuration option

Consider applying these changes:

-const DEFAULT_CONFIG:any = {
+interface ServerConfig {
+  PORT: number;
+  GAUZY_API_SERVER_URL: string;
+  NEXT_PUBLIC_GAUZY_API_SERVER_URL: string;
+  DESKTOP_WEB_SERVER_HOSTNAME: string;
+}
+
+interface GeneralConfig {
+  lang: string;
+  autoUpdate: boolean;
+  updateCheckPeriode: string;
+}
+
+interface AppConfig {
+  server: ServerConfig;
+  general: GeneralConfig;
+}
+
+/**
+ * Default configuration for the application
+ * @property {ServerConfig} server - Server-related configuration
+ * @property {GeneralConfig} general - General application settings
+ */
+const DEFAULT_CONFIG: AppConfig = {
   server: {
-    PORT: 3002,
+    PORT: process.env.SERVER_PORT ? parseInt(process.env.SERVER_PORT) : 3002,
-    GAUZY_API_SERVER_URL: 'http://localhost:3000',
+    GAUZY_API_SERVER_URL: process.env.GAUZY_API_SERVER_URL || 'http://localhost:3000',
-    NEXT_PUBLIC_GAUZY_API_SERVER_URL: 'http://localhost:3000',
+    NEXT_PUBLIC_GAUZY_API_SERVER_URL: process.env.NEXT_PUBLIC_GAUZY_API_SERVER_URL || 'http://localhost:3000',
     DESKTOP_WEB_SERVER_HOSTNAME: '0.0.0.0'
   },
   general: {
     lang: 'en',
     autoUpdate: true,
-    updateCheckPeriode: '1140'
+    updateCheckPeriode: '1140' // Time in minutes
   }
 }
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
const DEFAULT_CONFIG:any = {
server: {
PORT: 3002,
GAUZY_API_SERVER_URL: 'http://localhost:3000',
NEXT_PUBLIC_GAUZY_API_SERVER_URL: 'http://localhost:3000',
DESKTOP_WEB_SERVER_HOSTNAME: '0.0.0.0'
},
general: {
lang: 'en',
autoUpdate: true,
updateCheckPeriode: '1140'
}
}
interface ServerConfig {
PORT: number;
GAUZY_API_SERVER_URL: string;
NEXT_PUBLIC_GAUZY_API_SERVER_URL: string;
DESKTOP_WEB_SERVER_HOSTNAME: string;
}
interface GeneralConfig {
lang: string;
autoUpdate: boolean;
updateCheckPeriode: string;
}
interface AppConfig {
server: ServerConfig;
general: GeneralConfig;
}
/**
* Default configuration for the application
* @property {ServerConfig} server - Server-related configuration
* @property {GeneralConfig} general - General application settings
*/
const DEFAULT_CONFIG: AppConfig = {
server: {
PORT: process.env.SERVER_PORT ? parseInt(process.env.SERVER_PORT) : 3002,
GAUZY_API_SERVER_URL: process.env.GAUZY_API_SERVER_URL || 'http://localhost:3000',
NEXT_PUBLIC_GAUZY_API_SERVER_URL: process.env.NEXT_PUBLIC_GAUZY_API_SERVER_URL || 'http://localhost:3000',
DESKTOP_WEB_SERVER_HOSTNAME: '0.0.0.0'
},
general: {
lang: 'en',
autoUpdate: true,
updateCheckPeriode: '1140' // Time in minutes
}
}

export const LocalStore = {
getStore: (source: string | 'config'): WebServer | any => {
return store.get(source);
Expand All @@ -24,22 +37,15 @@ export const LocalStore = {


setDefaultServerConfig: () => {
const defaultConfig: WebServer | any = store.get('config');
if (!defaultConfig || !defaultConfig.server || !defaultConfig.general) {
const config: WebServer = {
server: {
PORT: 3002,
GAUZY_API_SERVER_URL: 'http://localhost:3000',
NEXT_PUBLIC_GAUZY_API_SERVER_URL: 'http://localhost:3000',
DESKTOP_WEB_SERVER_HOSTNAME: '0.0.0.0'
},
general: {
lang: 'en',
autoUpdate: true,
updateCheckPeriode: '30'
}
}
store.set({ config });
}
const defaultConfig: WebServer | any = store.get('config') || {};
Object.keys(DEFAULT_CONFIG).forEach((key) => {
Object.keys(DEFAULT_CONFIG[key]).forEach((keySub) => {
defaultConfig[key] = defaultConfig[key] || {};
defaultConfig[key][keySub] = defaultConfig[key][keySub] || DEFAULT_CONFIG[key][keySub];
})
})
store.set({
config: defaultConfig
});
Comment on lines +40 to +49
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Enhance robustness and efficiency of configuration management

The current implementation has several potential improvements:

  1. The nested iteration could be replaced with a more efficient deep merge
  2. Add error handling for malformed configurations
  3. Add validation for required fields
  4. Add type safety to the configuration merging process

Consider refactoring to:

-setDefaultServerConfig: () => {
-    const defaultConfig: WebServer | any = store.get('config') || {};
-    Object.keys(DEFAULT_CONFIG).forEach((key) => {
-        Object.keys(DEFAULT_CONFIG[key]).forEach((keySub) => {
-            defaultConfig[key] = defaultConfig[key] || {};
-            defaultConfig[key][keySub] = defaultConfig[key][keySub] || DEFAULT_CONFIG[key][keySub];
-        })
-    })
-    store.set({
-        config: defaultConfig
-    });
-}
+setDefaultServerConfig: () => {
+    try {
+        const storedConfig = store.get('config') as Partial<AppConfig> || {};
+        
+        // Deep merge with type safety
+        const mergedConfig = deepMerge<AppConfig>(DEFAULT_CONFIG, storedConfig);
+        
+        // Validate required fields
+        validateConfig(mergedConfig);
+        
+        store.set({ config: mergedConfig });
+    } catch (error) {
+        console.error('Failed to set default configuration:', error);
+        // Fallback to DEFAULT_CONFIG if stored config is corrupted
+        store.set({ config: DEFAULT_CONFIG });
+    }
+}

Add these helper functions:

function deepMerge<T>(target: T, source: Partial<T>): T {
    const result: T = { ...target };
    Object.keys(source).forEach(key => {
        const value = source[key as keyof T];
        if (value && typeof value === 'object') {
            result[key as keyof T] = deepMerge(
                target[key as keyof T],
                value as any
            );
        } else if (value !== undefined) {
            result[key as keyof T] = value as any;
        }
    });
    return result;
}

function validateConfig(config: AppConfig): void {
    const required = ['PORT', 'GAUZY_API_SERVER_URL'];
    required.forEach(field => {
        if (!config.server[field as keyof ServerConfig]) {
            throw new Error(`Missing required field: ${field}`);
        }
    });
}

}
};
43 changes: 21 additions & 22 deletions apps/server-web/src/main/main.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import path from 'path';
import { app, ipcMain, Tray, dialog, BrowserWindow, shell } from 'electron';
import { app, ipcMain, Tray, dialog, BrowserWindow, shell, Menu } from 'electron';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Consider improving type safety and menu initialization.

The menu system changes could benefit from better type safety and centralization:

  1. The appMenuItems array is typed as any which reduces type safety
  2. Menu initialization is scattered across multiple places

Consider these improvements:

- let appMenuItems: any = [];
+ interface MenuItem {
+   label: string;
+   click?: () => void;
+   submenu?: MenuItem[];
+ }
+ let appMenuItems: MenuItem[] = [];

Also applies to: 44-44, 95-95

import { DesktopServer } from './helpers/desktop-server';
import { LocalStore } from './helpers/services/libs/desktop-store';
import { EventEmitter } from 'events';
Expand All @@ -23,8 +23,6 @@ Object.assign(console, Log.functions);

app.name = config.DESCRIPTION;



const eventEmitter = new EventEmitter();

const controller = new AbortController();
Expand All @@ -43,6 +41,7 @@ let logWindow: BrowserWindow | null = null;
let setupWindow: BrowserWindow | any = null;
let SettingMenu: any = null;
let ServerWindowMenu: any = null;
const appMenu = new MenuBuilder(eventEmitter)

Log.hooks.push((message: any, transport) => {
if (transport !== Log.transports.file) {
Expand Down Expand Up @@ -93,6 +92,7 @@ i18nextMainBackend.on('initialized', () => {
});

let trayMenuItems: any = [];
let appMenuItems: any = [];

const RESOURCES_PATH = app.isPackaged
? path.join(process.resourcesPath, 'assets')
Expand Down Expand Up @@ -182,10 +182,7 @@ const createWindow = async (type: 'SETTING_WINDOW' | 'LOG_WINDOW' | 'SETUP_WINDO
settingWindow = null;
SettingMenu = null
});
if (!SettingMenu) {
SettingMenu = new MenuBuilder(settingWindow);
}
SettingMenu.buildMenu();
Menu.setApplicationMenu(appMenu.buildDefaultTemplate(appMenuItems, i18nextMainBackend))
break;
case 'LOG_WINDOW':
logWindow = new BrowserWindow(defaultOptionWindow);
Expand All @@ -196,10 +193,7 @@ const createWindow = async (type: 'SETTING_WINDOW' | 'LOG_WINDOW' | 'SETUP_WINDO
logWindow = null;
ServerWindowMenu = null
})
if (!ServerWindowMenu) {
ServerWindowMenu = new MenuBuilder(logWindow);
}
ServerWindowMenu.buildMenu();
Menu.setApplicationMenu(appMenu.buildDefaultTemplate(appMenuItems, i18nextMainBackend))
break;
case 'SETUP_WINDOW':
setupWindow = new BrowserWindow(defaultOptionWindow);
Expand All @@ -218,7 +212,7 @@ const createWindow = async (type: 'SETTING_WINDOW' | 'LOG_WINDOW' | 'SETUP_WINDO
const runServer = async () => {
console.log('Run the Server...');
try {
const envVal = getEnvApi();
const envVal: any = getEnvApi();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Strengthen type safety throughout the application.

While adding type annotation for envVal is good, consider extending type safety to other areas of the application.

Consider adding proper types instead of using any:

- const envVal: any = getEnvApi();
+ interface EnvConfig {
+   PORT: number;
+   NEXT_PUBLIC_GAUZY_API_SERVER_URL: string;
+   // Add other environment variables
+ }
+ const envVal: EnvConfig = getEnvApi();

Committable suggestion skipped: line range outside the PR's diff.


// Instantiate API and UI servers
await desktopServer.start(
Expand Down Expand Up @@ -262,14 +256,18 @@ const SendMessageToSettingWindow = (type: string, data: any) => {
}

const onInitApplication = () => {
LocalStore.setDefaultServerConfig(); // check and set default config
// check and set default config
LocalStore.setDefaultServerConfig();
createIntervalAutoUpdate()
trayMenuItems = trayMenuItems.length ? trayMenuItems : defaultTrayMenuItem(eventEmitter);
appMenuItems = appMenuItems.length ? appMenuItems : appMenu.defaultMenu();
tray = _initTray(trayMenuItems, getAssetPath('icons/icon.png'));
i18nextMainBackend.on('languageChanged', (lng) => {
if (i18nextMainBackend.isInitialized) {

trayMenuItems = trayMenuItems.length ? trayMenuItems : defaultTrayMenuItem(eventEmitter);
updateTrayMenu('none', {}, eventEmitter, tray, trayMenuItems, i18nextMainBackend);
Menu.setApplicationMenu(appMenu.buildDefaultTemplate(appMenuItems, i18nextMainBackend))
Comment on lines +259 to +270
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Enhance error handling in initialization sequence.

The initialization sequence lacks proper error handling and could benefit from debouncing frequent operations.

Consider adding error handling and debouncing:

+ import debounce from 'lodash/debounce';

  const onInitApplication = () => {
+   try {
      LocalStore.setDefaultServerConfig();
      createIntervalAutoUpdate()
      trayMenuItems = trayMenuItems.length ? trayMenuItems : defaultTrayMenuItem(eventEmitter);
      appMenuItems = appMenuItems.length ? appMenuItems : appMenu.defaultMenu();
      tray = _initTray(trayMenuItems, getAssetPath('icons/icon.png'));
+   } catch (error) {
+     console.error('Failed to initialize application:', error);
+     dialog.showErrorBox('Initialization Error', 'Failed to initialize application');
+   }

-   i18nextMainBackend.on('languageChanged', (lng) => {
+   i18nextMainBackend.on('languageChanged', debounce((lng) => {
      if (i18nextMainBackend.isInitialized) {
        trayMenuItems = trayMenuItems.length ? trayMenuItems : defaultTrayMenuItem(eventEmitter);
        updateTrayMenu('none', {}, eventEmitter, tray, trayMenuItems, i18nextMainBackend);
        Menu.setApplicationMenu(appMenu.buildDefaultTemplate(appMenuItems, i18nextMainBackend))
      }
-   });
+   }, 250));

Committable suggestion skipped: line range outside the PR's diff.

}
});
eventEmitter.on(EventLists.webServerStart, async () => {
Expand Down Expand Up @@ -425,6 +423,16 @@ const onInitApplication = () => {
const url = `http://127.0.0.1:${envConfig?.PORT}`
shell.openExternal(url)
})

eventEmitter.on(EventLists.SETTING_WINDOW_DEV, () => {
settingWindow?.webContents.toggleDevTools();
})

eventEmitter.on(EventLists.SERVER_WINDOW_DEV, () => {
logWindow?.webContents.toggleDevTools();
})
Comment on lines +427 to +433
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Add production safeguards for development features.

The dev tools toggle functionality should be restricted to development environments.

Consider adding environment checks:

  eventEmitter.on(EventLists.SETTING_WINDOW_DEV, () => {
+   if (process.env.NODE_ENV === 'development') {
      settingWindow?.webContents.toggleDevTools();
+   }
  })

  eventEmitter.on(EventLists.SERVER_WINDOW_DEV, () => {
+   if (process.env.NODE_ENV === 'development') {
      logWindow?.webContents.toggleDevTools();
+   }
  })
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
eventEmitter.on(EventLists.SETTING_WINDOW_DEV, () => {
settingWindow?.webContents.toggleDevTools();
})
eventEmitter.on(EventLists.SERVER_WINDOW_DEV, () => {
logWindow?.webContents.toggleDevTools();
})
eventEmitter.on(EventLists.SETTING_WINDOW_DEV, () => {
if (process.env.NODE_ENV === 'development') {
settingWindow?.webContents.toggleDevTools();
}
})
eventEmitter.on(EventLists.SERVER_WINDOW_DEV, () => {
if (process.env.NODE_ENV === 'development') {
logWindow?.webContents.toggleDevTools();
}
})

Comment on lines +427 to +433
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Consider restricting dev tools in production.

Developer tools events should only be registered in development mode to prevent unintended access in production.

-  eventEmitter.on(EventLists.SETTING_WINDOW_DEV, () => {
-    settingWindow?.webContents.toggleDevTools();
-  })
-
-  eventEmitter.on(EventLists.SERVER_WINDOW_DEV, () => {
-    logWindow?.webContents.toggleDevTools();
-  })
+  if (isDebug) {
+    eventEmitter.on(EventLists.SETTING_WINDOW_DEV, () => {
+      settingWindow?.webContents.toggleDevTools();
+    })
+
+    eventEmitter.on(EventLists.SERVER_WINDOW_DEV, () => {
+      logWindow?.webContents.toggleDevTools();
+    })
+  }

Committable suggestion skipped: line range outside the PR's diff.


eventEmitter.emit(EventLists.SERVER_WINDOW);
}

(async () => {
Expand Down Expand Up @@ -452,7 +460,6 @@ ipcMain.on('message', async (event, arg) => {
})

ipcMain.on(IPC_TYPES.SETTING_PAGE, async (event, arg) => {
console.log('main setting page', arg);
switch (arg.type) {
case SettingPageTypeMessage.saveSetting:
const existingConfig = getEnvApi();
Expand Down Expand Up @@ -512,13 +519,6 @@ ipcMain.on(IPC_TYPES.SETTING_PAGE, async (event, arg) => {
case SettingPageTypeMessage.themeChange:
eventEmitter.emit(EventLists.CHANGE_THEME, arg.data)
break;
default:
break;
}
})

ipcMain.on(IPC_TYPES.UPDATER_PAGE, (event, arg) => {
switch (arg.type) {
case SettingPageTypeMessage.updateSetting:
LocalStore.updateConfigSetting({
general: {
Expand All @@ -529,7 +529,6 @@ ipcMain.on(IPC_TYPES.UPDATER_PAGE, (event, arg) => {
createIntervalAutoUpdate()
event.sender.send(IPC_TYPES.UPDATER_PAGE, { type: SettingPageTypeMessage.updateSettingResponse, data: true })
break;

default:
break;
}
Expand Down
137 changes: 0 additions & 137 deletions apps/server-web/src/main/main_.ts

This file was deleted.

Loading
Loading