[tor-commits] [tor-browser/tor-browser-68.1.0esr-9.0-2] Bug 1568521 Tracking protection doorhanger's Enable/Disable states don't work r=VladBaicu

gk at torproject.org gk at torproject.org
Fri Sep 20 07:09:23 UTC 2019


commit c6eb1efb7d3ca6a9b5e19f6ec352ee1b129efbd3
Author: Andrei Lazar <andrei.a.lazar at softvision.ro>
Date:   Wed Jul 24 16:00:32 2019 +0000

    Bug 1568521 Tracking protection doorhanger's Enable/Disable states don't work r=VladBaicu
    
    Now using lastURI instead of principal and now we are using the right functions in order to test permissions.
    
    Differential Revision: https://phabricator.services.mozilla.com/D39190
    
    --HG--
    extra : moz-landing-system : lando
---
 mobile/android/chrome/content/PermissionsHelper.js | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/mobile/android/chrome/content/PermissionsHelper.js b/mobile/android/chrome/content/PermissionsHelper.js
index b25920872635..39556e756c84 100644
--- a/mobile/android/chrome/content/PermissionsHelper.js
+++ b/mobile/android/chrome/content/PermissionsHelper.js
@@ -145,6 +145,7 @@ var PermissionsHelper = {
    * @return A permission value defined in nsIPermissionManager.
    */
   getPermission: function getPermission(aPrincipal, aType) {
+    let aURI = BrowserApp.selectedBrowser.lastURI;
     // Password saving isn't a nsIPermissionManager permission type, so handle
     // it seperately.
     if (aType == "password") {
@@ -164,10 +165,10 @@ var PermissionsHelper = {
 
     // Geolocation consumers use testExactPermissionForPrincipal
     if (aType == "geolocation") {
-      return Services.perms.testExactPermissionForPrincipal(aPrincipal, aType);
+      return Services.perms.testExactPermissionFromPrincipal(aPrincipal, aType);
     }
 
-    return Services.perms.testPermissionForPrincipal(aPrincipal, aType);
+    return Services.perms.testPermissionFromPrincipal(aPrincipal, aType);
   },
 
   /**





More information about the tor-commits mailing list