Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: lib/devtools.js

Issue 29739603: Issue 6544 - Prevent requests sent by Chrome or Adblock Plus from being blocked (Closed)
Patch Set: Made logic more verbose Created April 9, 2018, 9:33 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | lib/requestBlocker.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/devtools.js
===================================================================
--- a/lib/devtools.js
+++ b/lib/devtools.js
@@ -135,13 +135,15 @@
thirdParty, sitekey,
specificOnly, filter)
{
- if (panels.size == 0)
- return;
-
- let request = {url, type, docDomain, thirdParty, sitekey, specificOnly};
- for (let [tabId, panel] of panels)
- if ((tabIds.length == 0 || tabIds.includes(tabId)) && isActivePanel(panel))
+ for (let tabId of tabIds)
+ {
+ let panel = getActivePanel(tabId);
+ if (panel)
+ {
+ let request = {url, type, docDomain, thirdParty, sitekey, specificOnly};
addRecord(panel, request, filter);
+ }
+ }
};
/**
« no previous file with comments | « no previous file | lib/requestBlocker.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld