r69884 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r69883‎ | r69884 | r69885 >
Date:18:00, 25 July 2010
Author:reedy
Status:ok
Tags:
Comment:
Fix some wrong usages of static method calls (actually belong to class instance)
Modified paths:
  • /trunk/phase3/includes/ZhClient.php (modified) (history)
  • /trunk/phase3/languages/classes/LanguageKk_cyrl.php (modified) (history)
  • /trunk/phase3/languages/classes/LanguageZh_hans.php (modified) (history)
  • /trunk/phase3/maintenance/checkSyntax.php (modified) (history)
  • /trunk/phase3/maintenance/installExtension.php (modified) (history)

Diff [purge]

Index: trunk/phase3/maintenance/installExtension.php
@@ -414,7 +414,7 @@
415415
416416 foreach ( $ff as $f ) {
417417 if ( is_dir( $f ) && !is_link( $f ) ) {
418 - $ok = ExtensionInstaller::copyDir( $f, $d );
 418+ $ok = $this->copyDir( $f, $d );
419419 if ( !$ok ) return false;
420420 }
421421 else {
@@ -444,7 +444,7 @@
445445 if ( is_link( $f ) ) continue; # skip link
446446
447447 if ( is_dir( $f ) ) {
448 - ExtensionInstaller::setPermissions( $f, $dirbits, $filebits );
 448+ $this->setPermissions( $f, $dirbits, $filebits );
449449 }
450450 else {
451451 if ( !chmod( $f, $filebits ) ) ExtensionInstaller::warn( "faield to set permissions for $f" );
Index: trunk/phase3/maintenance/checkSyntax.php
@@ -121,7 +121,7 @@
122122
123123 preg_match_all( '/^\s*[AM].{7}(.*?)\r?$/m', $output, $matches );
124124 foreach ( $matches[1] as $file ) {
125 - if ( self::isSuitableFile( $file ) && !is_dir( $file ) ) {
 125+ if ( $this->isSuitableFile( $file ) && !is_dir( $file ) ) {
126126 $this->mFiles[] = $file;
127127 }
128128 }
Index: trunk/phase3/includes/ZhClient.php
@@ -123,7 +123,7 @@
124124 $q = "SEG $len\n$text";
125125 $result = $this->query($q);
126126 if(!$result) {// fallback to character based segmentation
127 - $result = ZhClientFake::segment($text);
 127+ $result = $this->segment($text);
128128 }
129129 return $result;
130130 }
Index: trunk/phase3/languages/classes/LanguageKk_cyrl.php
@@ -37,7 +37,7 @@
3838 $secondPerson = array( "з" ); // 1st plural, 2nd formal
3939 $thirdPerson = array( "ы", "і" ); // 3rd
4040
41 - $lastLetter = self::lastLetter( $word, $allVowels );
 41+ $lastLetter = $this->lastLetter( $word, $allVowels );
4242 $wordEnding =& $lastLetter[0];
4343 $wordLastVowel =& $lastLetter[1];
4444
Index: trunk/phase3/languages/classes/LanguageZh_hans.php
@@ -25,7 +25,7 @@
2626 // Double-width roman characters
2727 $s = parent::normalizeForSearch( $s );
2828 $s = trim( $s );
29 - $s = self::segmentByWord( $s );
 29+ $s = $this->segmentByWord( $s );
3030
3131 wfProfileOut( __METHOD__ );
3232 return $s;

Status & tagging log