jenkins-bot has submitted this change and it was merged. (
https://gerrit.wikimedia.org/r/345471 )
Change subject: Add ?safemode=1 to disable user JS/CSS
......................................................................
Add ?safemode=1 to disable user JS/CSS
Bug: T152169
Change-Id: I112b7abf1cfa1330b2d4e6150018aad14c00b654
---
M includes/OutputPage.php
1 file changed, 5 insertions(+), 0 deletions(-)
Approvals:
Krinkle: Looks good to me, but someone else must approve
Sbisson: Looks good to me, approved
jenkins-bot: Verified
diff --git a/includes/OutputPage.php b/includes/OutputPage.php
index 9ecfa23..3cc9b76 100644
--- a/includes/OutputPage.php
+++ b/includes/OutputPage.php
@@ -2367,6 +2367,11 @@
if ( $this->mArticleBodyOnly ) {
echo $this->mBodytext;
} else {
+ // Enable safe mode if requested
+ if ( $this->getRequest()->getBool( 'safemode' ) ) {
+ $this->disallowUserJs();
+ }
+
$sk = $this->getSkin();
// add skin specific modules
$modules = $sk->getDefaultModules();
--
To view, visit https://gerrit.wikimedia.org/r/345471
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I112b7abf1cfa1330b2d4e6150018aad14c00b654
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Catrope <[email protected]>
Gerrit-Reviewer: Krinkle <[email protected]>
Gerrit-Reviewer: Sbisson <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits