Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

don't send messages to all windows in onBeforeRequest #9701

Closed
bridiver opened this issue Jun 25, 2017 · 0 comments · Fixed by #9702
Closed

don't send messages to all windows in onBeforeRequest #9701

bridiver opened this issue Jun 25, 2017 · 0 comments · Fixed by #9702

Comments

@bridiver
Copy link
Collaborator

bridiver commented Jun 25, 2017

Test plan

#9702 (comment)


https://github.com/brave/browser-laptop/blob/master/app/filtering.js#L140

BrowserWindow.getAllWindows().forEach((wnd) =>
          wnd.webContents.send(message, parentResourceName, {
            tabId: details.tabId,
            url: details.url
          }))

is inefficient and wasteful because the message only needs to go to one tab
related #9678 (review)

@bridiver bridiver self-assigned this Jun 25, 2017
@luixxiul luixxiul added this to the 0.18.x (Developer Channel) milestone Jun 25, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.