Bug 1502072 - Removing restriction of opening javascript places into new tabs. r=Gijs
authorJonathan Kingston <jkt@mozilla.com>
Mon, 25 Feb 2019 11:19:05 +0000
changeset 518776 b140842718773a64290100c9cf3738fb67df3542
parent 518775 29f06630e00e44ef1723813a38833dce52aea239
child 518777 e0f409bac9bd1b62d3cb7fa75352e4192f0d8422
push id10862
push userffxbld-merge
push dateMon, 11 Mar 2019 13:01:11 +0000
treeherdermozilla-beta@a2e7f5c935da [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersGijs
bugs1502072
milestone67.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1502072 - Removing restriction of opening javascript places into new tabs. r=Gijs Differential Revision: https://phabricator.services.mozilla.com/D20894
browser/components/places/PlacesUIUtils.jsm
--- a/browser/components/places/PlacesUIUtils.jsm
+++ b/browser/components/places/PlacesUIUtils.jsm
@@ -707,17 +707,17 @@ var PlacesUIUtils = {
         else
           this.markPageAsTyped(aNode.uri);
       }
 
       const isJavaScriptURL = aNode.uri.startsWith("javascript:");
       aWindow.openTrustedLinkIn(aNode.uri, aWhere, {
         allowPopups: isJavaScriptURL,
         inBackground: this.loadBookmarksInBackground,
-        allowInheritPrincipal: isJavaScriptURL && aWhere == "current",
+        allowInheritPrincipal: isJavaScriptURL,
         private: aPrivate,
       });
     }
   },
 
   /**
    * Helper for guessing scheme from an url string.
    * Used to avoid nsIURI overhead in frequently called UI functions.