r51147 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r51146‎ | r51147 | r51148 >
Date:08:33, 29 May 2009
Author:thedevilonline
Status:deferred
Tags:
Comment:
- Fixed a small bug with a function that's return wrong variable types
Modified paths:
  • /trunk/extensions/LocalisationUpdate/LocalisationUpdate.class.php (modified) (history)

Diff [purge]

Index: trunk/extensions/LocalisationUpdate/LocalisationUpdate.class.php
@@ -41,10 +41,10 @@
4242
4343 // Update all MW core messages
4444 $result = self::updateMediawikiMessages( $verbose );
45 -
 45+
4646 // Update all Extension messages
4747 foreach ( $wgExtensionMessagesFiles as $extension => $locFile ) {
48 - $result += self::updateExtensionMessages( $locFile, $extension, $verbose );
 48+ $result = self::updateExtensionMessages( $locFile, $extension, $verbose );
4949 }
5050
5151 // And output the result!
@@ -353,7 +353,7 @@
354354 $base_messages = array();
355355
356356 $basefilecontents = self::getFileContents( $basefile );
357 - if ( $basefilecontents === false || $basefilecontents === "" ) return array(); // Failed
 357+ if ( $basefilecontents === false || $basefilecontents === "" ) return 0; // Failed
358358
359359 // Cleanup the file where needed
360360 $basefilecontents = self::cleanupExtensionFile( $basefilecontents );
@@ -375,7 +375,7 @@
376376 eval( $basefilecontents );
377377
378378 $comparefilecontents = self::getFileContents( $comparefile );
379 - if ( $comparefilecontents === false || $comparefilecontents === "" ) return array(); // Failed
 379+ if ( $comparefilecontents === false || $comparefilecontents === "" ) return 0; // Failed
380380
381381 // Only get what we need
382382 $comparefilecontents = self::cleanupExtensionFile( $comparefilecontents );

Status & tagging log