From: Mark A. Hershberger Date: Sat, 4 Sep 2010 01:06:34 +0000 (+0000) Subject: w/s changes X-Git-Tag: 1.31.0-rc.0~35179 X-Git-Url: http://git.cyclocoop.org//%27%40script%40/%27?a=commitdiff_plain;h=5dbbca7331f618bd359fd14c1684f1990d6d02f1;p=lhc%2Fweb%2Fwiklou.git w/s changes --- diff --git a/includes/Exception.php b/includes/Exception.php index 0b77322db7..e89d94269b 100644 --- a/includes/Exception.php +++ b/includes/Exception.php @@ -229,7 +229,7 @@ class MWException extends Exception { function htmlFooter() { return ""; } - + /** * headers handled by subclass? */ diff --git a/includes/HttpFunctions.php b/includes/HttpFunctions.php index 946489584b..9123cc679e 100644 --- a/includes/HttpFunctions.php +++ b/includes/HttpFunctions.php @@ -26,7 +26,7 @@ class Http { * - sslVerifyCert (curl only) Verify SSL certificate * - caInfo (curl only) Provide CA information * - maxRedirects Maximum number of redirects to follow (defaults to 5) - * - followRedirects Whether to follow redirects (defaults to false). + * - followRedirects Whether to follow redirects (defaults to false). * Note: this should only be used when the target URL is trusted, * to avoid attacks on intranet services accessible by HTTP. * @return Mixed: (bool)false on failure or a string on success @@ -222,7 +222,7 @@ class HttpRequest { /** * Set the parameters of the request - + * @param $args Array * @todo overload the args param */ @@ -502,7 +502,7 @@ class HttpRequest { } /** - * Returns true if the backend can follow redirects. Overridden by the + * Returns true if the backend can follow redirects. Overridden by the * child classes. */ public function canFollowRedirects() { @@ -767,7 +767,7 @@ class CurlHttpRequest extends HttpRequest { if ( isset( $this->sslVerifyHost ) ) { $this->curlOptions[CURLOPT_SSL_VERIFYHOST] = $this->sslVerifyHost; } - + if ( isset( $this->sslVerifyCert ) ) { $this->curlOptions[CURLOPT_SSL_VERIFYPEER] = $this->sslVerifyCert; } @@ -800,7 +800,7 @@ class CurlHttpRequest extends HttpRequest { if ( ! @curl_setopt( $curlHandle, CURLOPT_FOLLOWLOCATION, true ) ) { wfDebug( __METHOD__.": Couldn't set CURLOPT_FOLLOWLOCATION. " . "Probably safe_mode or open_basedir is set.\n"); - // Continue the processing. If it were in curl_setopt_array, + // Continue the processing. If it were in curl_setopt_array, // processing would have halted on its entry } } diff --git a/includes/Skin.php b/includes/Skin.php index 99926b70ae..664c11f355 100644 --- a/includes/Skin.php +++ b/includes/Skin.php @@ -664,10 +664,10 @@ CSS; wfProfileOut( __METHOD__ ); } - + /** * Get the query to generate a dynamic stylesheet - * + * * @return array */ public static function getDynamicStylesheetQuery() { @@ -2140,14 +2140,14 @@ CSS; * Currently only used for MediaWiki:Sidebar (but may be used by Extensions) * * This is just a wrapper around addToSidebarPlain() for backwards compatibility - * + * * @param &$bar array * @param $message String */ function addToSidebar( &$bar, $message ) { $this->addToSidebarPlain( $bar, wfMsgForContent( $message ) ); } - + /** * Add content from plain text * @since 1.17 @@ -2205,12 +2205,12 @@ CSS; ); } else if ( (substr($line, 0, 2) == '{{') && (substr($line, -2) == '}}') ) { global $wgParser, $wgTitle; - + $line = substr($line, 2, strlen($line) - 4 ); - + if (is_null($wgParser->mOptions)) $wgParser->mOptions = new ParserOptions(); - + $wgParser->mOptions->setEditSection(false); $wikiBar[$heading] = $wgParser->parse( wfMsgForContentNoTrans( $line ) , $wgTitle, $wgParser->mOptions )->getText(); } else { @@ -2218,10 +2218,10 @@ CSS; } } } - + if ( count($wikiBar) > 0 ) $bar = array_merge($bar, $wikiBar); - + return $bar; } diff --git a/includes/db/Database.php b/includes/db/Database.php index 4f2217dadd..adee63415c 100644 --- a/includes/db/Database.php +++ b/includes/db/Database.php @@ -186,7 +186,7 @@ abstract class DatabaseBase implements DatabaseType { /** * Returns true if this database requires that SELECT DISTINCT queries require that all - ORDER BY expressions occur in the SELECT list per the SQL92 standard + ORDER BY expressions occur in the SELECT list per the SQL92 standard */ function standardSelectDistinct() { return true; @@ -2030,7 +2030,7 @@ abstract class DatabaseBase implements DatabaseType { * @return Database replication lag in seconds */ function getLag() { - return $this->mFakeSlaveLag; + return $this->mFakeSlaveLag; } /** @@ -2096,7 +2096,7 @@ abstract class DatabaseBase implements DatabaseType { throw $e; } } - + fclose( $fp ); return $error; } @@ -2554,16 +2554,16 @@ class DBConnectionError extends DBError { $outofdate
- - - - + + + + - - + +
- - + +
diff --git a/includes/filerepo/LocalFile.php b/includes/filerepo/LocalFile.php index 309010624f..22fb347378 100644 --- a/includes/filerepo/LocalFile.php +++ b/includes/filerepo/LocalFile.php @@ -73,7 +73,7 @@ class LocalFile extends File { $file->loadFromRow( $row ); return $file; } - + /** * Create a LocalFile from a SHA-1 key * Do not call this except from inside a repo class. @@ -91,7 +91,7 @@ class LocalFile extends File { return false; } } - + /** * Fields in the image table */ @@ -130,7 +130,7 @@ class LocalFile extends File { } /** - * Get the memcached key for the main data for this file, or false if + * Get the memcached key for the main data for this file, or false if * there is no access to the shared cache. */ function getCacheKey() { @@ -655,7 +655,7 @@ class LocalFile extends File { $opts['ORDER BY'] = "oi_timestamp $order"; $opts['USE INDEX'] = array( 'oldimage' => 'oi_name_timestamp' ); - wfRunHooks( 'LocalFile::getHistory', array( &$this, &$tables, &$fields, + wfRunHooks( 'LocalFile::getHistory', array( &$this, &$tables, &$fields, &$conds, &$opts, &$join_conds ) ); $res = $dbr->select( $tables, $fields, $conds, __METHOD__, $opts, $join_conds ); @@ -792,7 +792,7 @@ class LocalFile extends File { { if( is_null( $user ) ) { global $wgUser; - $user = $wgUser; + $user = $wgUser; } $dbw = $this->repo->getMasterDB(); @@ -914,7 +914,7 @@ class LocalFile extends File { $nullRevision = Revision::newNullRevision( $dbw, $descTitle->getArticleId(), $log->getRcComment(), false ); $nullRevision->insertOn( $dbw ); - + wfRunHooks( 'NewRevisionFromEditComplete', array( $article, $nullRevision, $latest, $user ) ); $article->updateRevisionOn( $dbw, $nullRevision ); @@ -1023,7 +1023,7 @@ class LocalFile extends File { // Purge the new image $this->purgeEverything(); } - + return $status; } @@ -1870,7 +1870,7 @@ class LocalFileMoveBatch { $dbw = $this->db; // Update current image - $dbw->update( + $dbw->update( 'image', array( 'img_name' => $this->newName ), array( 'img_name' => $this->oldName ), @@ -1902,7 +1902,7 @@ class LocalFileMoveBatch { /** * Generate triplets for FSRepo::storeBatch(). - */ + */ function getMoveTriplets() { $moves = array_merge( array( $this->cur ), $this->olds ); $triplets = array(); // The format is: (srcUrl, destZone, destUrl) @@ -1917,7 +1917,7 @@ class LocalFileMoveBatch { /** * Removes non-existent files from move batch. - */ + */ function removeNonexistentFiles( $triplets ) { $files = array(); foreach( $triplets as $file ) diff --git a/includes/installer/CliInstaller.php b/includes/installer/CliInstaller.php index 666f835d19..24d0fd7ec4 100644 --- a/includes/installer/CliInstaller.php +++ b/includes/installer/CliInstaller.php @@ -35,7 +35,7 @@ class CliInstaller extends CoreInstaller { /** * Constructor. - * + * * @param $siteName * @param $admin * @param $option Array @@ -59,7 +59,7 @@ class CliInstaller extends CoreInstaller { } $this->setVar( 'wgSitename', $siteName ); - + if ( $admin ) { $this->setVar( '_AdminName', $admin ); } @@ -96,7 +96,7 @@ class CliInstaller extends CoreInstaller { public function endStage( $step, $status ) { $warnings = $status->getWarningsArray(); - + if ( !$status->isOk() ) { $this->showStatusMessage( $status ); echo "\n"; @@ -107,7 +107,7 @@ class CliInstaller extends CoreInstaller { wfMsg( 'word-separator' ) ); } } - + $this->showMessage( wfMsg( 'config-install-step-done' ) ."\n"); } diff --git a/maintenance/parserTests.inc b/maintenance/parserTests.inc index 7f38defddb..05327c1065 100644 --- a/maintenance/parserTests.inc +++ b/maintenance/parserTests.inc @@ -657,7 +657,7 @@ class ParserTest { $db->query( "DROP TABLE IF EXISTS $newTableName" ); } elseif ( in_array( $wgDBtype, array( 'postgres', 'oracle' ) ) ) { /* DROPs wouldn't work due to Foreign Key Constraints (bug 14990, r58669) - * Use "DROP TABLE IF EXISTS $newTableName CASCADE" for postgres? That + * Use "DROP TABLE IF EXISTS $newTableName CASCADE" for postgres? That * syntax would also work for mysql. */ } elseif ( $db->tableExists( $tbl ) ) { diff --git a/maintenance/tests/LanguageConverterTest.php b/maintenance/tests/LanguageConverterTest.php index c37d2f683f..9fdcedc68d 100644 --- a/maintenance/tests/LanguageConverterTest.php +++ b/maintenance/tests/LanguageConverterTest.php @@ -93,7 +93,7 @@ class LanguageConverterTest extends PHPUnit_Framework_TestCase { $wgUser = User::newFromId( "admin" ); $wgUser->setId( 1 ); $wgUser->setOption( 'variant', 'tg-latn' ); // The user's data is ignored - // because the variant is set in the URL. + // because the variant is set in the URL. $this->assertEquals( 'tg', $this->lc->getPreferredVariant( true, false ) ); $this->assertEquals( 'tg', $this->lc->getPreferredVariant( true, true ) ); } diff --git a/maintenance/tests/UploadFromUrlTestSuite.php b/maintenance/tests/UploadFromUrlTestSuite.php index a439fd9b4a..8393eb7f6f 100644 --- a/maintenance/tests/UploadFromUrlTestSuite.php +++ b/maintenance/tests/UploadFromUrlTestSuite.php @@ -13,11 +13,11 @@ class UploadFromUrlTestSuite extends PHPUnit_Framework_TestSuite function setUp() { global $wgParser, $wgParserConf, $IP, $messageMemc, $wgMemc, $wgDeferredUpdateList, - $wgUser, $wgLang, $wgOut, $wgRequest, $wgStyleDirectory, $wgEnableParserCache, - $wgMessageCache, $wgUseDatabaseMessages, $wgMsgCacheExpiry, $parserMemc, - $wgNamespaceAliases, $wgNamespaceProtection, $wgLocalFileRepo, - $wgThumbnailScriptPath, $wgScriptPath, - $wgArticlePath, $wgStyleSheetPath, $wgScript, $wgStylePath; + $wgUser, $wgLang, $wgOut, $wgRequest, $wgStyleDirectory, $wgEnableParserCache, + $wgMessageCache, $wgUseDatabaseMessages, $wgMsgCacheExpiry, $parserMemc, + $wgNamespaceAliases, $wgNamespaceProtection, $wgLocalFileRepo, + $wgThumbnailScriptPath, $wgScriptPath, + $wgArticlePath, $wgStyleSheetPath, $wgScript, $wgStylePath; $wgScript = '/index.php'; $wgScriptPath = '/'; @@ -163,10 +163,10 @@ class UploadFromUrlTestSuite extends PHPUnit_Framework_TestSuite return $dir; } - public static function suite() - { - return new UploadFromUrlTestSuite( 'UploadFromUrlTest' ); - } + public static function suite() + { + return new UploadFromUrlTestSuite( 'UploadFromUrlTest' ); + } } diff --git a/maintenance/tests/selenium/Selenium.php b/maintenance/tests/selenium/Selenium.php index 2662a75c27..48e505dcd5 100644 --- a/maintenance/tests/selenium/Selenium.php +++ b/maintenance/tests/selenium/Selenium.php @@ -81,7 +81,7 @@ class Selenium { if ( $value != true ) { throw new Testing_Selenium_Exception( "Login Failed" ); } - + } public static function getInstance() { @@ -107,7 +107,7 @@ class Selenium { public function log( $message ) { $this->logger->write( $message ); } - + public function setUrl( $url ) { self::$url = $url; } diff --git a/maintenance/tests/selenium/SeleniumTestSuite.php b/maintenance/tests/selenium/SeleniumTestSuite.php index 3613576795..a86f5a9f19 100644 --- a/maintenance/tests/selenium/SeleniumTestSuite.php +++ b/maintenance/tests/selenium/SeleniumTestSuite.php @@ -15,7 +15,7 @@ class SeleniumTestSuite extends PHPUnit_Framework_TestSuite { if ( $this->isSetUp ) { return; } - $this->isSetUp = true; + $this->isSetUp = true; $this->selenium = Selenium::getInstance(); $this->selenium->start(); $this->login();