From c7408b9223b98b7c10a20c60ff09cc92f8458b60 Mon Sep 17 00:00:00 2001 From: Lupin Date: Sat, 11 Mar 2006 17:13:49 +0000 Subject: [PATCH] trailing whitespace removal --- includes/Article.php | 6 +++--- includes/Database.php | 12 ++++++------ includes/DefaultSettings.php | 6 +++--- includes/DifferenceEngine.php | 6 +++--- includes/ExternalStore.php | 4 ++-- includes/FakeTitle.php | 12 ++++++------ includes/GlobalFunctions.php | 6 +++--- includes/HttpFunctions.php | 2 +- includes/JobQueue.php | 16 ++++++++-------- includes/LinkFilter.php | 14 +++++++------- includes/Linker.php | 18 +++++++++--------- includes/LinksUpdate.php | 4 ++-- includes/LogPage.php | 2 +- includes/Parser.php | 18 +++++++++--------- includes/RawPage.php | 4 ++-- includes/SkinTemplate.php | 2 +- includes/SpecialRecentchanges.php | 4 ++-- includes/SpecialStatistics.php | 2 +- includes/SpecialUpload.php | 2 +- includes/Title.php | 10 +++++----- includes/Wiki.php | 4 ++-- 21 files changed, 77 insertions(+), 77 deletions(-) diff --git a/includes/Article.php b/includes/Article.php index 8b48d50ac3..e5ca9b7a7c 100644 --- a/includes/Article.php +++ b/includes/Article.php @@ -91,7 +91,7 @@ class Article { } else { return $rt->getFullURL(); } - } + } return $rt; } } @@ -1828,7 +1828,7 @@ class Article { } /** - * Get the last N authors + * Get the last N authors * @param int $num Number of revisions to get * @param string $revLatest The latest rev_id, selected from the master (optional) * @return array Array of authors, duplicates not removed @@ -1848,7 +1848,7 @@ class Article { 'page_namespace' => $this->mTitle->getNamespace(), 'page_title' => $this->mTitle->getDBkey(), 'rev_page = page_id' - ), $fname, $this->getSelectOptions( array( + ), $fname, $this->getSelectOptions( array( 'ORDER BY' => 'rev_timestamp DESC', 'LIMIT' => $num ) ) diff --git a/includes/Database.php b/includes/Database.php index 35525df738..ba7b1d6d58 100644 --- a/includes/Database.php +++ b/includes/Database.php @@ -1327,8 +1327,8 @@ class Database { * $conds may be "*" to copy the whole table * srcTable may be an array of tables. */ - function insertSelect( $destTable, $srcTable, $varMap, $conds, $fname = 'Database::insertSelect', - $options = array() ) + function insertSelect( $destTable, $srcTable, $varMap, $conds, $fname = 'Database::insertSelect', + $options = array() ) { $destTable = $this->tableName( $destTable ); if ( is_array( $options ) ) { @@ -1336,11 +1336,11 @@ class Database { } if( is_array( $srcTable ) ) { $srcTable = implode( ',', array_map( array( &$this, 'tableName' ), $srcTable ) ); - } else { + } else { $srcTable = $this->tableName( $srcTable ); } $sql = "INSERT $options INTO $destTable (" . implode( ',', array_keys( $varMap ) ) . ')' . - ' SELECT ' . implode( ',', $varMap ) . + ' SELECT ' . implode( ',', $varMap ) . " FROM $srcTable"; if ( $conds != '*' ) { $sql .= ' WHERE ' . $this->makeList( $conds, LIST_AND ); @@ -1649,7 +1649,7 @@ class Database { } /** - * Read and execute SQL commands from a file. + * Read and execute SQL commands from a file. * Returns true on success, error string on failure */ function sourceFile( $filename ) { @@ -1715,7 +1715,7 @@ class Database { } // Table prefixes - $ins = preg_replace_callback( '/\/\*(?:\$wgDBprefix|_)\*\/([a-z_]*)/', + $ins = preg_replace_callback( '/\/\*(?:\$wgDBprefix|_)\*\/([a-z_]*)/', array( &$this, 'tableNameCallback' ), $ins ); return $ins; } diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php index 1b9757bf37..97d0617cef 100644 --- a/includes/DefaultSettings.php +++ b/includes/DefaultSettings.php @@ -648,7 +648,7 @@ $wgMetaNamespaceTalk = false; $wgLocalInterwiki = 'w'; $wgInterwikiExpiry = 10800; # Expiry time for cache of interwiki table -/** Interwiki caching settings. +/** Interwiki caching settings. $wgInterwikiCache specifies path to constant database file This cdb database is generated by dumpInterwiki from maintenance and has such key formats: @@ -664,7 +664,7 @@ $wgInterwikiExpiry = 10800; # Expiry time for cache of interwiki table 3 - site levels $wgInterwikiFallbackSite - if unable to resolve from cache */ -$wgInterwikiCache = false; +$wgInterwikiCache = false; $wgInterwikiScopes = 3; $wgInterwikiFallbackSite = 'wiki'; @@ -1870,7 +1870,7 @@ $wgAllowCategorizedRecentChanges = false ; /** * Number of jobs to perform per request. May be less than one in which case * jobs are performed probabalistically. If this is zero, jobs will not be done - * during ordinary apache requests. In this case, maintenance/doJobs.php should + * during ordinary apache requests. In this case, maintenance/doJobs.php should * be run periodically. */ $wgJobRunRate = 1; diff --git a/includes/DifferenceEngine.php b/includes/DifferenceEngine.php index 492aa4ab15..cdd9e576d7 100644 --- a/includes/DifferenceEngine.php +++ b/includes/DifferenceEngine.php @@ -330,7 +330,7 @@ CONTROL; if ( $difftext ) { wfIncrStats( 'diff_cache_hit' ); $difftext = $this->localiseLineNumbers( $difftext ); - $difftext .= "\n\n"; + $difftext .= "\n\n"; wfProfileOut( $fname ); return $difftext; } @@ -378,7 +378,7 @@ CONTROL; dl('php_wikidiff.so'); } return $wgContLang->unsegementForDiff( wikidiff_do_diff( $otext, $ntext, 2 ) ); - } + } if ( $wgExternalDiffEngine == 'wikidiff2' ) { # Better external diff engine, the 2 may some day be dropped @@ -432,7 +432,7 @@ CONTROL; * Replace line numbers with the text in the user's language */ function localiseLineNumbers( $text ) { - return preg_replace_callback( '//', + return preg_replace_callback( '//', array( &$this, 'localiseLineNumbersCb' ), $text ); } diff --git a/includes/ExternalStore.php b/includes/ExternalStore.php index 71c4aaac22..79f1a5289e 100644 --- a/includes/ExternalStore.php +++ b/includes/ExternalStore.php @@ -53,8 +53,8 @@ class ExternalStore { /** * Store a data item to an external store, identified by a partial URL - * The protocol part is used to identify the class, the rest is passed to the - * class itself as a parameter. + * The protocol part is used to identify the class, the rest is passed to the + * class itself as a parameter. * Returns the URL of the stored data item, or false on error */ function insert( $url, $data ) { diff --git a/includes/FakeTitle.php b/includes/FakeTitle.php index a72f6eabf0..a6fd8401c3 100644 --- a/includes/FakeTitle.php +++ b/includes/FakeTitle.php @@ -15,15 +15,15 @@ class FakeTitle { function isLocal() { $this->error(); } function isTrans() { $this->error(); } function touchArray( $titles, $timestamp = '' ) { $this->error(); } - function getText() { $this->error(); } - function getPartialURL() { $this->error(); } + function getText() { $this->error(); } + function getPartialURL() { $this->error(); } function getDBkey() { $this->error(); } function getNamespace() { $this->error(); } function getNsText() { $this->error(); } function getSubjectNsText() { $this->error(); } - function getInterwiki() { $this->error(); } - function getFragment() { $this->error(); } - function getDefaultNamespace() { $this->error(); } + function getInterwiki() { $this->error(); } + function getFragment() { $this->error(); } + function getDefaultNamespace() { $this->error(); } function getIndexTitle() { $this->error(); } function getPrefixedDBkey() { $this->error(); } function getPrefixedText() { $this->error(); } @@ -36,7 +36,7 @@ class FakeTitle { function getInternalURL() { $this->error(); } function getEditURL() { $this->error(); } function getEscapedText() { $this->error(); } - function isExternal() { $this->error(); } + function isExternal() { $this->error(); } function isSemiProtected() { $this->error(); } function isProtected() { $this->error(); } function userIsWatching() { $this->error(); } diff --git a/includes/GlobalFunctions.php b/includes/GlobalFunctions.php index 2f2dbe7327..48374810e9 100644 --- a/includes/GlobalFunctions.php +++ b/includes/GlobalFunctions.php @@ -970,7 +970,7 @@ function wfEscapeShellArg( ) { } $delim = !$delim; } - // Double the backslashes before the end of the string, because + // Double the backslashes before the end of the string, because // we will soon add a quote if ( preg_match( '/^(.*?)(\\\\+)$/', $arg, $m ) ) { $arg = $m[1] . str_replace( '\\', '\\\\', $m[2] ); @@ -1713,7 +1713,7 @@ function in_string( $needle, $str ) { function wfUrlProtocols() { global $wgUrlProtocols; - // Support old-style $wgUrlProtocols strings, for backwards compatibility + // Support old-style $wgUrlProtocols strings, for backwards compatibility // with LocalSettings files from 1.5 if ( is_array( $wgUrlProtocols ) ) { $protocols = array(); @@ -1910,7 +1910,7 @@ function wfMakeUrlIndex( $url ) { function wfDoUpdates() { global $wgPostCommitUpdateList, $wgDeferredUpdateList; - foreach ( $wgDeferredUpdateList as $update ) { + foreach ( $wgDeferredUpdateList as $update ) { $update->doUpdate(); } foreach ( $wgPostCommitUpdateList as $update ) { diff --git a/includes/HttpFunctions.php b/includes/HttpFunctions.php index f23a14519f..fd2e87eebd 100644 --- a/includes/HttpFunctions.php +++ b/includes/HttpFunctions.php @@ -29,7 +29,7 @@ function wfGetHTTP( $url, $timeout = 'default' ) { # Set the referer to $wgTitle, even in command-line mode # This is useful for interwiki transclusion, where the foreign # server wants to know what the referring page is. - # $_SERVER['REQUEST_URI'] gives a less reliable indication of the + # $_SERVER['REQUEST_URI'] gives a less reliable indication of the # referring page. if ( is_object( $wgTitle ) ) { curl_setopt( $c, CURLOPT_REFERER, $wgTitle->getFullURL() ); diff --git a/includes/JobQueue.php b/includes/JobQueue.php index 3eddd50e7f..c9b2146f3a 100644 --- a/includes/JobQueue.php +++ b/includes/JobQueue.php @@ -7,9 +7,9 @@ if ( !defined( 'MEDIAWIKI' ) ) { class Job { var $command, $title, - $params, + $params, $id, - $removeDuplicates, + $removeDuplicates, $error; /*------------------------------------------------------------------------- @@ -17,7 +17,7 @@ class Job { *------------------------------------------------------------------------*/ /** * Add an array of refreshLinks jobs to the queue - * @param array $titles Array of title objects. + * @param array $titles Array of title objects. * @static */ function queueLinksJobs( $titles ) { @@ -42,7 +42,7 @@ class Job { $dbr =& wfGetDB( DB_SLAVE ); // Get a job from the slave - $row = $dbr->selectRow( 'job', '*', '', $fname, + $row = $dbr->selectRow( 'job', '*', '', $fname, array( 'ORDER BY' => 'job_id', 'LIMIT' => 1 ) ); @@ -60,7 +60,7 @@ class Job { if ( !$affected ) { // Failed, someone else beat us to it // Try getting a random row - $row = $dbw->selectRow( 'job', array( 'MIN(job_id) as minjob', + $row = $dbw->selectRow( 'job', array( 'MIN(job_id) as minjob', 'MAX(job_id) as maxjob' ), '', $fname ); if ( $row === false || is_null( $row->minjob ) || is_null( $row->maxjob ) ) { // No jobs to get @@ -68,7 +68,7 @@ class Job { return false; } // Get the random row - $row = $dbw->selectRow( 'job', '*', + $row = $dbw->selectRow( 'job', '*', array( 'job_id' => mt_rand( $row->minjob, $row->maxjob ) ), $fname ); if ( $row === false ) { // Random job gone before we got the chance to select it @@ -86,7 +86,7 @@ class Job { // Give up wfProfileOut( $fname ); return false; - } + } } // If execution got to here, there's a row in $row that has been deleted from the database @@ -204,7 +204,7 @@ class Job { return $s; } else { return "{$this->command} {$this->params}"; - } + } } function getLastError() { diff --git a/includes/LinkFilter.php b/includes/LinkFilter.php index 0008c6a1e2..e03b59dd60 100644 --- a/includes/LinkFilter.php +++ b/includes/LinkFilter.php @@ -4,8 +4,8 @@ * Some functions to help implement an external link filter for spam control. * * TODO: implement the filter. Currently these are just some functions to help - * maintenance/cleanupSpam.php remove links to a single specified domain. The - * next thing is to implement functions for checking a given page against a big + * maintenance/cleanupSpam.php remove links to a single specified domain. The + * next thing is to implement functions for checking a given page against a big * list of domains. * * Another cool thing to do would be a web interface for fast spam removal. @@ -33,15 +33,15 @@ class LinkFilter { } /** - * Make a string to go after an SQL LIKE, which will match the specified + * Make a string to go after an SQL LIKE, which will match the specified * string. There are several kinds of filter entry: - * *.domain.com - Produces http://com.domain.%, matches domain.com + * *.domain.com - Produces http://com.domain.%, matches domain.com * and www.domain.com * domain.com - Produces http://com.domain./%, matches domain.com * or domain.com/ but not www.domain.com - * *.domain.com/x - Produces http://com.domain.%/x%, matches + * *.domain.com/x - Produces http://com.domain.%/x%, matches * www.domain.com/xy - * domain.com/x - Produces http://com.domain./x%, matches + * domain.com/x - Produces http://com.domain./x%, matches * domain.com/xy but not www.domain.com/xy * * Asterisks in any other location are considered invalid. @@ -61,7 +61,7 @@ class LinkFilter { $subdomains = false; } // No stray asterisks, that could cause confusion - // It's not simple or efficient to handle it properly so we don't + // It's not simple or efficient to handle it properly so we don't // handle it at all. if ( strpos( $filterEntry, '*' ) !== false ) { return false; diff --git a/includes/Linker.php b/includes/Linker.php index 4b180ef213..75161bbb66 100644 --- a/includes/Linker.php +++ b/includes/Linker.php @@ -84,7 +84,7 @@ class Linker { * @param string $text Link text * @param string $query Optional query part * @param string $trail Optional trail. Alphabetic characters at the start of this string will - * be included in the link text. Other characters will be appended after + * be included in the link text. Other characters will be appended after * the end of the link. */ function makeLink( $title, $text = '', $query = '', $trail = '' ) { @@ -109,7 +109,7 @@ class Linker { * @param string $text Link text * @param string $query Optional query part * @param string $trail Optional trail. Alphabetic characters at the start of this string will - * be included in the link text. Other characters will be appended after + * be included in the link text. Other characters will be appended after * the end of the link. */ function makeKnownLink( $title, $text = '', $query = '', $trail = '', $prefix = '',$aprops = '') { @@ -130,7 +130,7 @@ class Linker { * @param string $text Link text * @param string $query Optional query part * @param string $trail Optional trail. Alphabetic characters at the start of this string will - * be included in the link text. Other characters will be appended after + * be included in the link text. Other characters will be appended after * the end of the link. */ function makeBrokenLink( $title, $text = '', $query = '', $trail = '' ) { @@ -151,7 +151,7 @@ class Linker { * @param string $text Link text * @param string $query Optional query part * @param string $trail Optional trail. Alphabetic characters at the start of this string will - * be included in the link text. Other characters will be appended after + * be included in the link text. Other characters will be appended after * the end of the link. */ function makeStubLink( $title, $text = '', $query = '', $trail = '' ) { @@ -165,7 +165,7 @@ class Linker { } /** - * Make a link for a title which may or may not be in the database. If you need to + * Make a link for a title which may or may not be in the database. If you need to * call this lots of times, pre-fill the link cache with a LinkBatch, otherwise each * call to this will result in a DB query. * @@ -173,7 +173,7 @@ class Linker { * @param string $text Link text * @param string $query Optional query part * @param string $trail Optional trail. Alphabetic characters at the start of this string will - * be included in the link text. Other characters will be appended after + * be included in the link text. Other characters will be appended after * the end of the link. */ function makeLinkObj( $nt, $text= '', $query = '', $trail = '', $prefix = '' ) { @@ -266,7 +266,7 @@ class Linker { } /** - * Make a link for a title which definitely exists. This is faster than makeLinkObj because + * Make a link for a title which definitely exists. This is faster than makeLinkObj because * it doesn't have to do a database query. It's also valid for interwiki titles and special * pages. * @@ -326,7 +326,7 @@ class Linker { * @param string $text Link text * @param string $query Optional query part * @param string $trail Optional trail. Alphabetic characters at the start of this string will - * be included in the link text. Other characters will be appended after + * be included in the link text. Other characters will be appended after * the end of the link. */ function makeBrokenLinkObj( $nt, $text = '', $query = '', $trail = '', $prefix = '' ) { @@ -365,7 +365,7 @@ class Linker { * @param string $text Link text * @param string $query Optional query part * @param string $trail Optional trail. Alphabetic characters at the start of this string will - * be included in the link text. Other characters will be appended after + * be included in the link text. Other characters will be appended after * the end of the link. */ function makeStubLinkObj( $nt, $text = '', $query = '', $trail = '', $prefix = '' ) { diff --git a/includes/LinksUpdate.php b/includes/LinksUpdate.php index e997724852..46dc1ca26c 100644 --- a/includes/LinksUpdate.php +++ b/includes/LinksUpdate.php @@ -184,7 +184,7 @@ class LinksUpdate { $this->mDb->delete( $table, array( $fromField => $this->mId ), $fname ); if ( count( $insertions ) ) { # The link array was constructed without FOR UPDATE, so there may be collisions - # This may cause minor link table inconsistencies, which is better than + # This may cause minor link table inconsistencies, which is better than # crippling the site with lock contention. $this->mDb->insert( $table, $insertions, $fname, array( 'IGNORE' ) ); } @@ -371,7 +371,7 @@ class LinksUpdate { } /** - * Given an array of existing external links, returns those links which are not + * Given an array of existing external links, returns those links which are not * in $this and thus should be deleted. * @access private */ diff --git a/includes/LogPage.php b/includes/LogPage.php index 5874546309..a1ad8c980b 100644 --- a/includes/LogPage.php +++ b/includes/LogPage.php @@ -84,7 +84,7 @@ class LogPage { } require_once( 'RecentChange.php' ); - RecentChange::notifyLog( $now, $titleObj, $wgUser, $rcComment, '', + RecentChange::notifyLog( $now, $titleObj, $wgUser, $rcComment, '', $this->type, $this->action, $this->target, $this->comment, $this->params ); } return true; diff --git a/includes/Parser.php b/includes/Parser.php index 3281865fea..3b5d119f40 100644 --- a/includes/Parser.php +++ b/includes/Parser.php @@ -627,9 +627,9 @@ class Parser $process = proc_open("$wgTidyBin -config $wgTidyConf $wgTidyOpts$opts", $descriptorspec, $pipes); if (is_resource($process)) { // Theoretically, this style of communication could cause a deadlock - // here. If the stdout buffer fills up, then writes to stdin could + // here. If the stdout buffer fills up, then writes to stdin could // block. This doesn't appear to happen with tidy, because tidy only - // writes to stdout after it's finished reading from stdin. Search + // writes to stdout after it's finished reading from stdin. Search // for tidyParseStdin and tidySaveStdout in console/tidy.c fwrite($pipes[0], $text); fclose($pipes[0]); @@ -1225,12 +1225,12 @@ class Parser /** * Replace unusual URL escape codes with their equivalent characters - * @param string + * @param string * @return string * @static */ function replaceUnusualEscapes( $url ) { - return preg_replace_callback( '/%[0-9A-Fa-f]{2}/', + return preg_replace_callback( '/%[0-9A-Fa-f]{2}/', array( 'Parser', 'replaceUnusualEscapesCallback' ), $url ); } @@ -2371,7 +2371,7 @@ class Parser $fname = 'Parser::braceSubstitution'; wfProfileIn( $fname ); - # Flags + # Flags $found = false; # $text has been filled $nowiki = false; # wiki markup in $text should be escaped $noparse = false; # Unsafe HTML tags should not be stripped, etc. @@ -2738,7 +2738,7 @@ class Parser } /** - * Fetch the unparsed text of a template and register a reference to it. + * Fetch the unparsed text of a template and register a reference to it. */ function fetchTemplate( $title ) { $text = false; @@ -3022,7 +3022,7 @@ class Parser $canonized_headline = preg_replace( '/<.*?' . '>/','',$canonized_headline ); $tocline = trim( $canonized_headline ); # Save headline for section edit hint before it's escaped - $headline_hint = trim( $canonized_headline ); + $headline_hint = trim( $canonized_headline ); $canonized_headline = Sanitizer::escapeId( $tocline ); $refers[$headlineCount] = $canonized_headline; @@ -3278,7 +3278,7 @@ class Parser # Signatures $sigText = $this->getUserSig( $user ); - $text = strtr( $text, array( + $text = strtr( $text, array( '~~~~~' => $d, '~~~~' => "$sigText $d", '~~~' => $sigText @@ -3783,7 +3783,7 @@ class Parser $this->mOutput->mCacheTime = -1; } - /**#@+ + /**#@+ * Callback from the Sanitizer for expanding items found in HTML attribute * values, so they can be safely tested and escaped. * @param string $text diff --git a/includes/RawPage.php b/includes/RawPage.php index 780ec7c56f..119f0c9d2f 100644 --- a/includes/RawPage.php +++ b/includes/RawPage.php @@ -43,14 +43,14 @@ class RawPage { $oldid = $this->mRequest->getInt( 'oldid' ); switch ( $wgRequest->getText( 'direction' ) ) { - case 'next': + case 'next': # output next revision, or nothing if there isn't one if ( $oldid ) { $oldid = $this->mTitle->getNextRevisionId( $oldid ); } $oldid = $oldid ? $oldid : -1; break; - case 'prev': + case 'prev': # output previous revision, or nothing if there isn't one if ( ! $oldid ) { # get the current revision so we can get the penultimate one diff --git a/includes/SkinTemplate.php b/includes/SkinTemplate.php index 040e253c2d..625b19c1dc 100644 --- a/includes/SkinTemplate.php +++ b/includes/SkinTemplate.php @@ -288,7 +288,7 @@ class SkinTemplate extends Skin { $sep = str_replace("_", " ", wfMsgHtml("newtalkseperator")); $msgs = array(); foreach ($newtalks as $newtalk) { - $msgs[] = wfElement("a", + $msgs[] = wfElement("a", array('href' => $newtalk["link"]), $newtalk["wiki"]); } $parts = implode($sep, $msgs); diff --git a/includes/SpecialRecentchanges.php b/includes/SpecialRecentchanges.php index 66b427687d..5f5c81b972 100644 --- a/includes/SpecialRecentchanges.php +++ b/includes/SpecialRecentchanges.php @@ -72,7 +72,7 @@ function wfSpecialRecentchanges( $par, $specialPage ) { $hideliu = $wgRequest->getBool( 'hideliu', $defaults['hideliu'] ); $hidepatrolled = $wgRequest->getBool( 'hidepatrolled', $defaults['hidepatrolled'] ); $hidemyself = $wgRequest->getBool ( 'hidemyself', $defaults['hidemyself'] ); - $from = $wgRequest->getVal( 'from', $defaults['from'] ); + $from = $wgRequest->getVal( 'from', $defaults['from'] ); # Get query parameters from path if( $par ) { @@ -504,7 +504,7 @@ function rcOptionsPanel( $defaults, $nondefaults ) { array( 'hideliu' => 1-$options['hideliu'] ), $nondefaults); $patrLink = makeOptionsLink( $showhide[1-$options['hidepatrolled']], array( 'hidepatrolled' => 1-$options['hidepatrolled'] ), $nondefaults); - $myselfLink = makeOptionsLink( $showhide[1-$options['hidemyself']], + $myselfLink = makeOptionsLink( $showhide[1-$options['hidemyself']], array( 'hidemyself' => 1-$options['hidemyself'] ), $nondefaults); $hl = wfMsg( 'showhideminor', $minorLink, $botLink, $liuLink, $patrLink, $myselfLink ); diff --git a/includes/SpecialStatistics.php b/includes/SpecialStatistics.php index ad4a1baa54..080e6d8844 100644 --- a/includes/SpecialStatistics.php +++ b/includes/SpecialStatistics.php @@ -46,7 +46,7 @@ function wfSpecialStatistics() { $res = $dbr->query( $sql, $fname ); $userRow = $dbr->fetchObject( $res ); $users = $userRow->total; - } + } $admins = $dbr->selectField( 'user_groups', 'COUNT(*)', array( 'ug_group' => 'sysop' ), $fname ); $numJobs = $dbr->selectField( 'job', 'COUNT(*)', '', $fname ); diff --git a/includes/SpecialUpload.php b/includes/SpecialUpload.php index 5e8cdea8d1..8bdfd8e296 100644 --- a/includes/SpecialUpload.php +++ b/includes/SpecialUpload.php @@ -114,7 +114,7 @@ class UploadForm { } else { $wgOut->errorPage( 'uploadnologin', 'uploadnologintext' ); return; - } + } # Check blocks if( $wgUser->isBlocked() ) { diff --git a/includes/Title.php b/includes/Title.php index 09af48dd1f..35b22da988 100644 --- a/includes/Title.php +++ b/includes/Title.php @@ -441,11 +441,11 @@ class Title { $site = $wgInterwikiFallbackSite; } $value = dba_fetch("{$wgDBname}:{$key}", $db); - if ($value=='' and $wgInterwikiScopes>=3) { + if ($value=='' and $wgInterwikiScopes>=3) { /* try site-level */ $value = dba_fetch("_{$site}:{$key}", $db); } - if ($value=='' and $wgInterwikiScopes>=2) { + if ($value=='' and $wgInterwikiScopes>=2) { /* try globals */ $value = dba_fetch("__global:{$key}", $db); } @@ -765,8 +765,8 @@ class Title { if ( $this->isExternal() ) { $url = $this->getFullURL(); if ( $query ) { - // This is currently only used for edit section links in the - // context of interwiki transclusion. In theory we should + // This is currently only used for edit section links in the + // context of interwiki transclusion. In theory we should // append the query to the end of any existing query string, // but interwiki transclusion is already broken in that case. $url .= "?$query"; @@ -1407,7 +1407,7 @@ class Title { continue; } - # If there's an initial colon after the interwiki, that also + # If there's an initial colon after the interwiki, that also # resets the default namespace if ( $t !== '' && $t[0] == ':' ) { $this->mNamespace = NS_MAIN; diff --git a/includes/Wiki.php b/includes/Wiki.php index 133d511585..0a0bd42eb3 100644 --- a/includes/Wiki.php +++ b/includes/Wiki.php @@ -202,7 +202,7 @@ class MediaWiki { $article = $this->articleFromTitle( $title ); // Namespace might change when using redirects - if( $action == 'view' && !$request->getVal( 'oldid' ) && + if( $action == 'view' && !$request->getVal( 'oldid' ) && $request->getVal( 'redirect' ) != 'no' ) { $dbr=&wfGetDB(DB_SLAVE); @@ -267,7 +267,7 @@ class MediaWiki { foreach( $updates as $up ) { $up->doUpdate(); } - wfProfileOut( 'MediaWiki::doUpdates' ); + wfProfileOut( 'MediaWiki::doUpdates' ); } /** -- 2.20.1