Bug 1531650 - remove addons.mozilla.org Screenshots exception. r=aswan a=pascalc
authorIan Bicking <ibicking@mozilla.com>
Sun, 07 Apr 2019 16:51:33 +0300
changeset 526003 e8d66492c9631daf52758892782d864762d3ccc7
parent 526002 ee00e620926a5bf8af78b41d91fd8b670af57634
child 526004 31a325ace8acdb81052224ca85f4f051e7fa9412
push id2032
push userffxbld-merge
push dateMon, 13 May 2019 09:36:57 +0000
treeherdermozilla-release@455c1065dcbe [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersaswan, pascalc
bugs1531650
milestone67.0
Bug 1531650 - remove addons.mozilla.org Screenshots exception. r=aswan a=pascalc Summary: In the past Screenshots was not permitted to work on addons.mozilla.org, but now with the mozillaAddons permission this restriction has been removed, and so the onboarding exception for addons.mozilla.org no longer needs to exist. Reviewers: aswan Reviewed By: aswan Bug #: 1531650 Differential Revision: https://phabricator.services.mozilla.com/D25997
browser/extensions/screenshots/background/main.js
--- a/browser/extensions/screenshots/background/main.js
+++ b/browser/extensions/screenshots/background/main.js
@@ -184,17 +184,17 @@ this.main = (function() {
     return false;
   }
 
   function isBlacklistedUrl(url) {
     // These specific domains are not allowed for general WebExtension permission reasons
     // Discussion: https://bugzilla.mozilla.org/show_bug.cgi?id=1310082
     // List of domains copied from: https://dxr.mozilla.org/mozilla-central/source/browser/app/permissions#18-19
     // Note we disable it here to be informative, the security check is done in WebExtension code
-    const badDomains = ["addons.mozilla.org", "testpilot.firefox.com"];
+    const badDomains = ["testpilot.firefox.com"];
     let domain = url.replace(/^https?:\/\//i, "");
     domain = domain.replace(/\/.*/, "").replace(/:.*/, "");
     domain = domain.toLowerCase();
     return badDomains.includes(domain);
   }
 
   communication.register("sendEvent", (sender, ...args) => {
     catcher.watchPromise(sendEvent(...args));