From 63601400e476c6cf43d985f3e7b9864681695ed4 Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Fri, 18 Jan 2013 16:46:04 +0100 Subject: Update to MediaWiki 1.20.2 this update includes: * adjusted Arch Linux skin * updated FluxBBAuthPlugin * patch for https://bugzilla.wikimedia.org/show_bug.cgi?id=44024 --- extensions/Gadgets/Gadgets_body.php | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'extensions/Gadgets/Gadgets_body.php') diff --git a/extensions/Gadgets/Gadgets_body.php b/extensions/Gadgets/Gadgets_body.php index 4869d8c2..330a1541 100644 --- a/extensions/Gadgets/Gadgets_body.php +++ b/extensions/Gadgets/Gadgets_body.php @@ -87,7 +87,7 @@ class GadgetHooks { } if ( $section !== '' ) { - $section = wfMsgExt( "gadget-section-$section", 'parseinline' ); + $section = wfMessage( "gadget-section-$section" )->parse(); if ( count ( $available ) ) { $options[$section] = $available; @@ -103,7 +103,7 @@ class GadgetHooks { 'label' => ' ', 'default' => Xml::tags( 'tr', array(), Xml::tags( 'td', array( 'colspan' => 2 ), - wfMsgExt( 'gadgets-prefstext', 'parse' ) ) ), + wfMessage( 'gadgets-prefstext' )->parseAsBlock() ) ), 'section' => 'gadgets', 'raw' => 1, 'rawrow' => 1, @@ -152,8 +152,6 @@ class GadgetHooks { * @return bool */ public static function beforePageDisplay( $out ) { - global $wgUser; - wfProfileIn( __METHOD__ ); $gadgets = Gadget::loadList(); @@ -169,8 +167,9 @@ class GadgetHooks { /** * @var $gadget Gadget */ + $user = $out->getUser(); foreach ( $gadgets as $gadget ) { - if ( $gadget->isEnabled( $wgUser ) && $gadget->isAllowed( $wgUser ) ) { + if ( $gadget->isEnabled( $user ) && $gadget->isAllowed( $user ) ) { if ( $gadget->hasModule() ) { $out->addModuleStyles( $gadget->getModuleName() ); $out->addModules( $gadget->getModuleName() ); -- cgit v1.2.2