From 8a8d29e6b903adae48884bf5d6afea4f94d8a75f Mon Sep 17 00:00:00 2001 From: Manav Rathi Date: Mon, 6 May 2024 16:29:51 +0530 Subject: [PATCH] Fix loading of preload scripts --- desktop/src/main.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/desktop/src/main.ts b/desktop/src/main.ts index 5a3e3dac4..242303ccf 100644 --- a/desktop/src/main.ts +++ b/desktop/src/main.ts @@ -142,7 +142,7 @@ const createMainWindow = () => { // Create the main window. This'll show our web content. const window = new BrowserWindow({ webPreferences: { - preload: path.join(app.getAppPath(), "preload.js"), + preload: path.join(__dirname, "preload.js"), sandbox: true, }, // The color to show in the window until the web content gets loaded.