r73389 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r73388‎ | r73389 | r73390 >
Date:18:41, 20 September 2010
Author:tparscal
Status:resolved
Tags:
Comment:
Fixed regression in r73037 that caused Vector extension to load modules on non-vector skins.
Modified paths:
  • /trunk/extensions/Vector/Vector.hooks.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Vector/Vector.hooks.php
@@ -141,10 +141,12 @@
142142 * @param $skin Skin current skin
143143 */
144144 public static function beforePageDisplay( $out, $skin ) {
145 - // Add modules for enabled features
146 - foreach ( self::$features as $name => $feature ) {
147 - if ( isset( $feature['modules'] ) && self::isEnabled( $name ) ) {
148 - $out->addModules( $feature['modules'] );
 145+ if ( $skin instanceof VectorSkin ) {
 146+ // Add modules for enabled features
 147+ foreach ( self::$features as $name => $feature ) {
 148+ if ( isset( $feature['modules'] ) && self::isEnabled( $name ) ) {
 149+ $out->addModules( $feature['modules'] );
 150+ }
149151 }
150152 }
151153 return true;

Follow-up revisions

RevisionCommit summaryAuthorDate
r73390Fixed skin name from r73389maxsem18:46, 20 September 2010

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r73037Ported JavaScript from UsabiltyIntiative/Vectortparscal01:31, 15 September 2010

Status & tagging log