w/s changes: “svn diff -x-w” is clean

This commit is contained in:
Mark A. Hershberger 2011-08-01 16:01:13 +00:00
parent 6a569d46b7
commit 97969f7d99
4 changed files with 22 additions and 22 deletions

View file

@ -135,7 +135,7 @@ class LinksUpdate {
# External links
$existing = $this->getExistingExternals();
$this->incrTableUpdate( 'externallinks', 'el', $this->getExternalDeletions( $existing ),
$this->getExternalInsertions( $existing ) );
$this->getExternalInsertions( $existing ) );
# Language links
$existing = $this->getExistingInterlangs();
@ -497,16 +497,16 @@ class LinksUpdate {
* @private
*/
function getInterlangInsertions( $existing = array() ) {
$diffs = array_diff_assoc( $this->mInterlangs, $existing );
$arr = array();
foreach( $diffs as $lang => $title ) {
$arr[] = array(
'll_from' => $this->mId,
'll_lang' => $lang,
'll_title' => $title
);
}
return $arr;
$diffs = array_diff_assoc( $this->mInterlangs, $existing );
$arr = array();
foreach( $diffs as $lang => $title ) {
$arr[] = array(
'll_from' => $this->mId,
'll_lang' => $lang,
'll_title' => $title
);
}
return $arr;
}
/**
@ -612,7 +612,7 @@ class LinksUpdate {
* @private
*/
function getInterlangDeletions( $existing ) {
return array_diff_assoc( $existing, $this->mInterlangs );
return array_diff_assoc( $existing, $this->mInterlangs );
}
/**

View file

@ -1250,7 +1250,7 @@ class Preferences {
if ( $wgLocalTZoffset == date( 'Z' ) / 60 ) {
$server_tz_msg = wfMsg( 'timezoneuseserverdefault', $wgLocaltimezone );
} else {
$tzstring = sprintf( '%+03d:%02d', floor( $wgLocalTZoffset / 60 ), abs( $wgLocalTZoffset ) % 60 );
$tzstring = sprintf( '%+03d:%02d', floor( $wgLocalTZoffset / 60 ), abs( $wgLocalTZoffset ) % 60 );
$server_tz_msg = wfMsg( 'timezoneuseserverdefault', $tzstring );
}
$opt[$server_tz_msg] = "System|$wgLocalTZoffset";

View file

@ -175,7 +175,7 @@ class DatabaseMysql extends DatabaseBase {
return $row;
}
function fetchRow( $res ) {
function fetchRow( $res ) {
if ( $res instanceof ResultWrapper ) {
$res = $res->result;
}
@ -432,7 +432,7 @@ class DatabaseMysql extends DatabaseBase {
}
return false;
}
/**
* Wait for the slave to catch up to a given master position.
*
@ -672,7 +672,7 @@ class DatabaseMysql extends DatabaseBase {
}
$this->query( $query, $fname );
}
/**
* List all tables on the database
*
@ -692,7 +692,7 @@ class DatabaseMysql extends DatabaseBase {
$endArray[] = $table;
}
}
return $endArray;
}

View file

@ -7,14 +7,14 @@ class ArticleTablesTest extends MediaWikiLangTestCase {
function testbug14404() {
global $wgUser, $wgContLang, $wgLanguageCode, $wgLang;
$title = Title::newFromText("Bug 14404");
$article = new Article( $title );
$wgUser = new User();
$wgUser->mRights['*'] = array( 'createpage', 'edit', 'purge' );
$wgLanguageCode = 'es';
$wgContLang = Language::factory( 'es' );
$wgLang = Language::factory( 'fr' );
$status = $article->doEdit( '{{:{{int:history}}}}', 'Test code for bug 14404', 0 );
$templates1 = $article->getUsedTemplates();
@ -22,13 +22,13 @@ class ArticleTablesTest extends MediaWikiLangTestCase {
$wgLang = Language::factory( 'de' );
$article->mParserOptions = null; // Let it pick the new user language
$article->mPreparedEdit = false; // In order to force the rerendering of the same wikitext
// We need an edit, a purge is not enough to regenerate the tables
$status = $article->doEdit( '{{:{{int:history}}}}', 'Test code for bug 14404', EDIT_UPDATE );
$templates2 = $article->getUsedTemplates();
$this->assertEquals( $templates1, $templates2 );
$this->assertEquals( $templates1[0]->getFullText(), 'Historial' );
}
}