Allow pages to reload themselves

This might help with TikTok's WAF interstitials
This commit is contained in:
Max Goodhart
2026-02-01 19:11:57 -08:00
parent 5ba0aba252
commit 77352deb97

View File

@@ -162,6 +162,10 @@ export default class StreamWindow extends EventEmitter<StreamWindowEventMap> {
// Prevent view pages from navigating away from the specified URL.
view.webContents.on('will-navigate', (ev) => {
if (ev.url === view.webContents.getURL()) {
console.log('Allowing page to reload:', ev.url)
return
}
ev.preventDefault()
})