mirror of
https://github.com/th-ch/youtube-music.git
synced 2026-01-11 10:31:47 +00:00
Prepare migration for sandboxing (path.join in preload)
This commit is contained in:
10
index.js
10
index.js
@ -136,12 +136,12 @@ function createMainWindow() {
|
||||
preload: path.join(__dirname, "preload.js"),
|
||||
nodeIntegrationInSubFrames: true,
|
||||
affinity: "main-window", // main window, and addition windows should work in one process
|
||||
...(isTesting()
|
||||
...(!isTesting()
|
||||
? {
|
||||
// Only necessary when testing with Spectron
|
||||
contextIsolation: false,
|
||||
nodeIntegration: true,
|
||||
}
|
||||
// Sandbox is only enabled in tests for now
|
||||
// See https://www.electronjs.org/docs/latest/tutorial/sandbox#preload-scripts
|
||||
sandbox: false,
|
||||
}
|
||||
: undefined),
|
||||
},
|
||||
frame: !is.macOS() && !useInlineMenu,
|
||||
|
||||
Reference in New Issue
Block a user