зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1804829 - Avoid last use of location.hostname on about:neterror page. r=prathiksha
It looks like hostname is sometimes undefined, which triggers a Fluent error. The HOST_NAME is determined from location.href, and falls back to an empty string value about which Fluent is much happier. Differential Revision: https://phabricator.services.mozilla.com/D164538
This commit is contained in:
Родитель
4db1f81ea9
Коммит
146a3e1023
|
@ -308,7 +308,7 @@ function initPage() {
|
|||
document.getElementById("errorShortDesc").hidden = true;
|
||||
|
||||
document.l10n.setAttributes(longDesc, "csp-xfo-blocked-long-desc", {
|
||||
hostname: document.location.hostname ?? "", // FIXME - should this be HOST_NAME?
|
||||
hostname: HOST_NAME,
|
||||
});
|
||||
longDesc = null;
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче