diff --git a/electron/main/webview.ts b/electron/main/webview.ts index 8036dda6d..8646b4eaf 100644 --- a/electron/main/webview.ts +++ b/electron/main/webview.ts @@ -269,10 +269,8 @@ export class WebViewManager { if (!webViewInfo.view.webContents.isDestroyed()) { webViewInfo.view.webContents.removeAllListeners() - webViewInfo.view.webContents.session.clearCache() - webViewInfo.view.webContents.session.clearStorageData({ - storages: ['cookies', 'localstorage', 'websql', 'indexdb', 'serviceworkers', 'cachestorage'] - }) + // REMOVED: clearCache() and clearStorageData() to prevent clearing main window's storage + // since all webviews share session.defaultSession with the main window } // remove webview from parent container