From e69fba7692027b2d7d8b7e37e69954d0a5553869 Mon Sep 17 00:00:00 2001 From: kevinlawler Date: Thu, 11 May 2017 15:43:15 -0700 Subject: [PATCH] skip over master brave window when querying brave/browser-laptop#8811 --- lib/browser/api/extensions.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/browser/api/extensions.js b/lib/browser/api/extensions.js index b11f119710..d05588ec57 100644 --- a/lib/browser/api/extensions.js +++ b/lib/browser/api/extensions.js @@ -344,6 +344,11 @@ const tabsQuery = function (queryInfo = {}, useCurrentWindowId = false) { var result = [] tabIds.forEach((tabId) => { + // never add the master Brave container window + if (tabValues[tabId].url.indexOf('chrome://') === 0) { + return + } + // delete tab from the list if any key doesn't match if (!queryKeys.map((queryKey) => (tabValues[tabId][queryKey] === queryInfo[queryKey])).includes(false)) { result.push(tabValues[tabId])