diff options
author | hackademix <giorgio@maone.net> | 2019-04-08 21:37:35 +0200 |
---|---|---|
committer | hackademix <giorgio@maone.net> | 2019-04-08 21:37:35 +0200 |
commit | 2bee3260b45b559eb3bc75c6421dc7e573571cdb (patch) | |
tree | 0b03d83f1dd8419e1db191e79b5f6313f5322515 /main_background.js | |
parent | 4221db4850905c535a9197ae4369012ef9fd1575 (diff) |
Fixed UI inconsistencies when whitelisting/blacklisting through wide wildcard matching.
Diffstat (limited to 'main_background.js')
-rw-r--r-- | main_background.js | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/main_background.js b/main_background.js index 5943fb8..ba88f15 100644 --- a/main_background.js +++ b/main_background.js @@ -134,6 +134,10 @@ async function createReport(initializer) { template.url = url; template.site = ListStore.siteItem(url); template.siteStatus = listManager.getStatus(template.site); + let list = {"whitelisted": whitelist, "blacklisted": blacklist}[template.siteStatus]; + if (list) { + template.listedSite = ListManager.siteMatch(template.site, list); + } return template; } @@ -750,7 +754,7 @@ async function get_script(response, url, tabId = -1, whitelisted = false, index let reason = site ? `All ${site} whitelisted by user` : "Address whitelisted by user"; - addReportEntry(tabId, url, {"whitelisted": [site, reason], url}); + addReportEntry(tabId, url, {"whitelisted": [site || url, reason], url}); } if (response.startsWith("javascript:")) return result(response); |