Index: trunk/phase3/tests/phpunit/includes/ArticleTablesTest.php |
— | — | @@ -7,14 +7,14 @@ |
8 | 8 | |
9 | 9 | function testbug14404() { |
10 | 10 | global $wgUser, $wgContLang, $wgLanguageCode, $wgLang; |
11 | | - |
| 11 | + |
12 | 12 | $title = Title::newFromText("Bug 14404"); |
13 | 13 | $article = new Article( $title ); |
14 | 14 | $wgUser = new User(); |
15 | 15 | $wgUser->mRights['*'] = array( 'createpage', 'edit', 'purge' ); |
16 | 16 | $wgLanguageCode = 'es'; |
17 | 17 | $wgContLang = Language::factory( 'es' ); |
18 | | - |
| 18 | + |
19 | 19 | $wgLang = Language::factory( 'fr' ); |
20 | 20 | $status = $article->doEdit( '{{:{{int:history}}}}', 'Test code for bug 14404', 0 ); |
21 | 21 | $templates1 = $article->getUsedTemplates(); |
— | — | @@ -22,13 +22,13 @@ |
23 | 23 | $wgLang = Language::factory( 'de' ); |
24 | 24 | $article->mParserOptions = null; // Let it pick the new user language |
25 | 25 | $article->mPreparedEdit = false; // In order to force the rerendering of the same wikitext |
26 | | - |
| 26 | + |
27 | 27 | // We need an edit, a purge is not enough to regenerate the tables |
28 | 28 | $status = $article->doEdit( '{{:{{int:history}}}}', 'Test code for bug 14404', EDIT_UPDATE ); |
29 | 29 | $templates2 = $article->getUsedTemplates(); |
30 | | - |
| 30 | + |
31 | 31 | $this->assertEquals( $templates1, $templates2 ); |
32 | 32 | $this->assertEquals( $templates1[0]->getFullText(), 'Historial' ); |
33 | 33 | } |
34 | | - |
| 34 | + |
35 | 35 | } |
Index: trunk/phase3/includes/db/DatabaseMysql.php |
— | — | @@ -175,7 +175,7 @@ |
176 | 176 | return $row; |
177 | 177 | } |
178 | 178 | |
179 | | - function fetchRow( $res ) { |
| 179 | + function fetchRow( $res ) { |
180 | 180 | if ( $res instanceof ResultWrapper ) { |
181 | 181 | $res = $res->result; |
182 | 182 | } |
— | — | @@ -432,7 +432,7 @@ |
433 | 433 | } |
434 | 434 | return false; |
435 | 435 | } |
436 | | - |
| 436 | + |
437 | 437 | /** |
438 | 438 | * Wait for the slave to catch up to a given master position. |
439 | 439 | * |
— | — | @@ -672,7 +672,7 @@ |
673 | 673 | } |
674 | 674 | $this->query( $query, $fname ); |
675 | 675 | } |
676 | | - |
| 676 | + |
677 | 677 | /** |
678 | 678 | * List all tables on the database |
679 | 679 | * |
— | — | @@ -692,7 +692,7 @@ |
693 | 693 | $endArray[] = $table; |
694 | 694 | } |
695 | 695 | } |
696 | | - |
| 696 | + |
697 | 697 | return $endArray; |
698 | 698 | } |
699 | 699 | |
Index: trunk/phase3/includes/LinksUpdate.php |
— | — | @@ -135,7 +135,7 @@ |
136 | 136 | # External links |
137 | 137 | $existing = $this->getExistingExternals(); |
138 | 138 | $this->incrTableUpdate( 'externallinks', 'el', $this->getExternalDeletions( $existing ), |
139 | | - $this->getExternalInsertions( $existing ) ); |
| 139 | + $this->getExternalInsertions( $existing ) ); |
140 | 140 | |
141 | 141 | # Language links |
142 | 142 | $existing = $this->getExistingInterlangs(); |
— | — | @@ -497,16 +497,16 @@ |
498 | 498 | * @private |
499 | 499 | */ |
500 | 500 | function getInterlangInsertions( $existing = array() ) { |
501 | | - $diffs = array_diff_assoc( $this->mInterlangs, $existing ); |
502 | | - $arr = array(); |
503 | | - foreach( $diffs as $lang => $title ) { |
504 | | - $arr[] = array( |
505 | | - 'll_from' => $this->mId, |
506 | | - 'll_lang' => $lang, |
507 | | - 'll_title' => $title |
508 | | - ); |
509 | | - } |
510 | | - return $arr; |
| 501 | + $diffs = array_diff_assoc( $this->mInterlangs, $existing ); |
| 502 | + $arr = array(); |
| 503 | + foreach( $diffs as $lang => $title ) { |
| 504 | + $arr[] = array( |
| 505 | + 'll_from' => $this->mId, |
| 506 | + 'll_lang' => $lang, |
| 507 | + 'll_title' => $title |
| 508 | + ); |
| 509 | + } |
| 510 | + return $arr; |
511 | 511 | } |
512 | 512 | |
513 | 513 | /** |
— | — | @@ -612,7 +612,7 @@ |
613 | 613 | * @private |
614 | 614 | */ |
615 | 615 | function getInterlangDeletions( $existing ) { |
616 | | - return array_diff_assoc( $existing, $this->mInterlangs ); |
| 616 | + return array_diff_assoc( $existing, $this->mInterlangs ); |
617 | 617 | } |
618 | 618 | |
619 | 619 | /** |
Index: trunk/phase3/includes/Preferences.php |
— | — | @@ -1250,7 +1250,7 @@ |
1251 | 1251 | if ( $wgLocalTZoffset == date( 'Z' ) / 60 ) { |
1252 | 1252 | $server_tz_msg = wfMsg( 'timezoneuseserverdefault', $wgLocaltimezone ); |
1253 | 1253 | } else { |
1254 | | - $tzstring = sprintf( '%+03d:%02d', floor( $wgLocalTZoffset / 60 ), abs( $wgLocalTZoffset ) % 60 ); |
| 1254 | + $tzstring = sprintf( '%+03d:%02d', floor( $wgLocalTZoffset / 60 ), abs( $wgLocalTZoffset ) % 60 ); |
1255 | 1255 | $server_tz_msg = wfMsg( 'timezoneuseserverdefault', $tzstring ); |
1256 | 1256 | } |
1257 | 1257 | $opt[$server_tz_msg] = "System|$wgLocalTZoffset"; |