Fix webviews for electron 7

Caused by #83796

Also re-enables the webview tests
This commit is contained in:
Matt Bierner
2020-01-09 15:06:11 -08:00
parent ad97bd7493
commit c8123dee96
2 changed files with 3 additions and 2 deletions

View File

@@ -191,7 +191,8 @@ export class CodeApplication extends Disposable {
webPreferences.nodeIntegration = false;
// Verify URLs being loaded
if (isValidWebviewSource(params.src) && isValidWebviewSource(webPreferences.preload)) {
// https://github.com/electron/electron/issues/21553
if (isValidWebviewSource(params.src) && isValidWebviewSource((webPreferences as { preloadURL: string }).preloadURL)) {
return;
}