From 32a6c8795a95f8b5480a987cf0e76414c1813a41 Mon Sep 17 00:00:00 2001 From: chalbin73 <59101580+chalbin73@users.noreply.github.com> Date: Wed, 4 Aug 2021 13:02:08 +0200 Subject: [PATCH] Fix: correct a problem making the app unusable in latests versions of electron Set enableRemoteModule to true, and contextIsolation to false as their default values were not correct (this caused a lot errors in controllers scripts, making the app unusable) --- AhMyth-Server/app/main.js | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/AhMyth-Server/app/main.js b/AhMyth-Server/app/main.js index 2b848bba..a64f6653 100644 --- a/AhMyth-Server/app/main.js +++ b/AhMyth-Server/app/main.js @@ -36,7 +36,9 @@ function createWindow() { toolbar: false, fullscreen: false, webPreferences: { - nodeIntegration: true + nodeIntegration: true, + enableRemoteModule: true, + contextIsolation: false } }); @@ -70,7 +72,9 @@ function createWindow() { transparent: true, frame: false, webPreferences: { - nodeIntegration: true + nodeIntegration: true, + enableRemoteModule: true, + contextIsolation: false } }); @@ -158,7 +162,9 @@ ipcMain.on('SocketIO:Listen', function (event, port) { resizable: false, toolbar: false, webPreferences: { - nodeIntegration: true + nodeIntegration: true, + enableRemoteModule: true, + contextIsolation: false } }); @@ -223,7 +229,9 @@ ipcMain.on('openLabWindow', function (e, page, index) { resizable: false, frame: false, webPreferences: { - nodeIntegration: true + nodeIntegration: true, + enableRemoteModule: true, + contextIsolation: false } })