From e292b64fa0adc285ecfedf76df932844a6440c32 Mon Sep 17 00:00:00 2001 From: John Kleinschmidt Date: Sat, 23 Nov 2024 16:54:32 -0500 Subject: [PATCH] fixup dont destroy webcontents for now --- spec/lib/window-helpers.ts | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/spec/lib/window-helpers.ts b/spec/lib/window-helpers.ts index e3dc62b6a2..df0c350668 100644 --- a/spec/lib/window-helpers.ts +++ b/spec/lib/window-helpers.ts @@ -60,11 +60,14 @@ export async function closeAllWindows (assertNotWindows = false) { export async function cleanupWebContents () { let webContentsDestroyed = 0; const existingWCS = webContents.getAllWebContents(); + webContentsDestroyed = existingWCS.length; + /* for (const contents of existingWCS) { - /*const isDestroyed = once(contents, 'destroyed'); + const isDestroyed = once(contents, 'destroyed'); contents.destroy(); - await isDestroyed;*/ + await isDestroyed; webContentsDestroyed++; } + */ return webContentsDestroyed; }