r53924 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r53923‎ | r53924 | r53925 >
Date:06:46, 29 July 2009
Author:nikerabbit
Status:ok
Tags:
Comment:
Bugfixes
Modified paths:
  • /trunk/extensions/Translate/SpecialTranslationChanges.php (modified) (history)
  • /trunk/extensions/Translate/scripts/autoexport.php (modified) (history)
  • /trunk/extensions/Translate/utils/MessageIndex.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Translate/scripts/autoexport.php
@@ -85,9 +85,10 @@
8686 $group = false;
8787 $code = false;
8888
 89+ // TODO: fixme
8990 list( $pieces, ) = explode( '/', $wgContLang->lcfirst( $row->rc_title ), 2 );
9091
91 - $mg = TranslateUtils::messageKeyToGroup( $row->rc_namespace . ':' . $pieces );
 92+ $mg = TranslateUtils::messageKeyToGroup( $row->rc_namespace, $pieces );
9293 if ( !is_null( $mg ) ) $group = $mg;
9394
9495 if ( strpos( $row->rc_title, '/' ) !== false ) {
Index: trunk/extensions/Translate/SpecialTranslationChanges.php
@@ -66,7 +66,7 @@
6767 list( $pieces, ) = explode( '/', $wgContLang->lcfirst( $row->rc_title ), 2 );
6868
6969 $group = 'Unknown';
70 - $mg = TranslateUtils::messageKeyToGroup( $row->rc_namespace . ':' . $pieces );
 70+ $mg = TranslateUtils::messageKeyToGroup( $row->rc_namespace, ':' . $pieces );
7171 if ( !is_null( $mg ) ) $group = $mg;
7272
7373 $lang = 'site';
Index: trunk/extensions/Translate/utils/MessageIndex.php
@@ -42,7 +42,7 @@
4343
4444 foreach ( $groups as $g ) {
4545 # the cache is split per namespace for efficieny
46 - if ( $namespace !== null && $g->namespaces[0] !== $namespace )
 46+ if ( $namespace !== null && $g->getNamespace() !== $namespace )
4747 continue;
4848
4949 # Skip meta thingies
@@ -74,7 +74,7 @@
7575
7676 STDOUT( "$id ", 'main' );
7777
78 - $namespace = $g->namespaces[0];
 78+ $namespace = $g->getNamespace();
7979
8080 foreach ( $messages as $key => $data ) {
8181 # Force all keys to lower case, because the case doesn't matter and it is

Follow-up revisions

RevisionCommit summaryAuthorDate
r57923Fix bug introduced in r53924 causing Special:TranslationChanges to break. ns:...siebrand21:53, 19 October 2009

Status & tagging log