r58213 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r58212‎ | r58213 | r58214 >
Date:20:42, 27 October 2009
Author:catrope
Status:ok
Tags:
Comment:
LocalisationUpdate: Don't ignore messages whose translations didn't exist at the time of the last update; this should fix some observed weirdness like http://translatewiki.net/w/i.php?title=User_talk:GerardM&diff=0&oldid=1598881
Modified paths:
  • /trunk/extensions/LocalisationUpdate/LocalisationUpdate.class.php (modified) (history)

Diff [purge]

Index: trunk/extensions/LocalisationUpdate/LocalisationUpdate.class.php
@@ -298,13 +298,14 @@
299299
300300 $new_messages = self::readFile( $langcode );
301301 foreach ( $changedStrings as $key => $value ) {
302 - // If this message wasn't changed in English, and is in fact set
303 - if ( !isset( $forbiddenKeys[$key] ) && isset( $compare_messages[$key] ) ) {
 302+ // If this message wasn't changed in English
 303+ if ( !isset( $forbiddenKeys[$key] ) ) {
304304 $new_messages[$key] = $base_messages[$key];
305305
306306 // Output extra logmessages when needed
307307 if ( $verbose ) {
308 - self::myLog( "Updated message {$key} from '{$compare_messages[$key]}' to '{$base_messages[$key]}'" );
 308+ $oldmsg = isset( $compare_messages[$key] ) ? "'{$compare_messages[$key]}'" : 'not set';
 309+ self::myLog( "Updated message {$key} from $oldmsg to '{$base_messages[$key]}'" );
309310 }
310311
311312 // Update the counter

Follow-up revisions

RevisionCommit summaryAuthorDate
r58216Merge r58213 (LocalisationUpdate fix)catrope20:59, 27 October 2009

Status & tagging log