зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1633710 - Move js uri.AsciiHost to principal r=ckerschb
Differential Revision: https://phabricator.services.mozilla.com/D73239
This commit is contained in:
Родитель
008827b6ac
Коммит
47570a169b
|
@ -297,7 +297,7 @@ var SiteDataManager = {
|
|||
let principal = Services.scriptSecurityManager.createContentPrincipalFromOrigin(
|
||||
item.origin
|
||||
);
|
||||
if (principal.URI.asciiHost == asciiHost) {
|
||||
if (principal.asciiHost == asciiHost) {
|
||||
resolve(true);
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -245,11 +245,11 @@ interface nsIPrincipal : nsISerializable
|
|||
*/
|
||||
readonly attribute ACString hostPort;
|
||||
|
||||
/**
|
||||
/**
|
||||
* Returns the "host:port" portion of the
|
||||
* Principals URI, if any.
|
||||
*/
|
||||
[noscript] readonly attribute ACString asciiHost;
|
||||
readonly attribute ACString asciiHost;
|
||||
|
||||
/**
|
||||
* Returns the "host" portion of the
|
||||
|
|
|
@ -110,7 +110,7 @@ function run_test() {
|
|||
pm.addFromPrincipal(principal, "utf8", 1);
|
||||
Assert.notEqual(Services.perms.all.length, 0);
|
||||
var ace = Services.perms.all[0];
|
||||
Assert.equal(ace.principal.URI.asciiHost, aceref);
|
||||
Assert.equal(ace.principal.asciiHost, aceref);
|
||||
Assert.equal(Services.perms.all.length > 1, false);
|
||||
|
||||
// test removeAll()
|
||||
|
|
|
@ -63,7 +63,7 @@ PurgeTrackerService.prototype = {
|
|||
}
|
||||
let host;
|
||||
try {
|
||||
host = principal.URI.asciiHost;
|
||||
host = principal.asciiHost;
|
||||
} catch (error) {
|
||||
return false;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче