diff --git a/mailnews/base/content/junkLog.js b/mailnews/base/content/junkLog.js index 07f3b47496..28afda6f5b 100644 --- a/mailnews/base/content/junkLog.js +++ b/mailnews/base/content/junkLog.js @@ -13,7 +13,7 @@ var gLogFile; function onLoad() { gLogView = document.getElementById("logView"); - gLogView.docShell.allowJavascript = false; // for security, disable JS + gLogView.browsingContext.allowJavascript = false; // for security, disable JS gLogView.addEventListener("load", () => { addStyling(); diff --git a/mailnews/base/src/nsMsgContentPolicy.cpp b/mailnews/base/src/nsMsgContentPolicy.cpp index e9e84bffba..0a3d37c208 100644 --- a/mailnews/base/src/nsMsgContentPolicy.cpp +++ b/mailnews/base/src/nsMsgContentPolicy.cpp @@ -841,7 +841,7 @@ nsresult nsMsgContentPolicy::SetDisableItemsOnMailNewsUrlDocshells( if (!isAllowedContent) { // Disable JavaScript on message URLs. - rv = docShell->SetAllowJavascript(false); + rv = browsingContext->SetAllowJavascript(false); NS_ENSURE_SUCCESS(rv, rv); rv = browsingContext->SetAllowContentRetargetingOnChildren(false); NS_ENSURE_SUCCESS(rv, rv); @@ -871,7 +871,7 @@ nsresult nsMsgContentPolicy::SetDisableItemsOnMailNewsUrlDocshells( NS_ENSURE_SUCCESS(rv, rv); } else { // JavaScript is allowed on non-message URLs. - rv = docShell->SetAllowJavascript(true); + rv = browsingContext->SetAllowJavascript(true); NS_ENSURE_SUCCESS(rv, rv); rv = browsingContext->SetAllowContentRetargetingOnChildren(true); NS_ENSURE_SUCCESS(rv, rv); diff --git a/mailnews/search/content/viewLog.js b/mailnews/search/content/viewLog.js index 291639b78d..3d9ccad5e4 100644 --- a/mailnews/search/content/viewLog.js +++ b/mailnews/search/content/viewLog.js @@ -19,7 +19,7 @@ function onLoad() { gLogView = document.getElementById("logView"); // for security, disable JS - gLogView.docShell.allowJavascript = false; + gLogView.browsingContext.allowJavascript = false; MailE10SUtils.loadURI(gLogView, gFilterList.logURL); }