fix some spacing
authorumherirrender <umherirrender_de.wp@web.de>
Sun, 3 Feb 2013 19:28:43 +0000 (20:28 +0100)
committerGerrit Code Review <gerrit@wikimedia.org>
Mon, 4 Feb 2013 20:04:26 +0000 (20:04 +0000)
Change-Id: Ia9650be8b791fd2f0ccbc099436918a9d12d9968

44 files changed:
includes/installer/CliInstaller.php
includes/installer/DatabaseInstaller.php
includes/installer/DatabaseUpdater.php
includes/installer/Installer.php
includes/installer/MysqlInstaller.php
includes/installer/MysqlUpdater.php
includes/installer/OracleInstaller.php
includes/installer/OracleUpdater.php
includes/installer/PostgresUpdater.php
includes/installer/WebInstaller.php
includes/installer/WebInstallerOutput.php
includes/installer/WebInstallerPage.php
includes/objectcache/EhcacheBagOStuff.php
includes/objectcache/MemcachedClient.php
includes/objectcache/SqlBagOStuff.php
includes/specials/SpecialAllpages.php
includes/specials/SpecialBlankpage.php
includes/specials/SpecialBlock.php
includes/specials/SpecialBlockList.php
includes/specials/SpecialBooksources.php
includes/specials/SpecialCategories.php
includes/specials/SpecialContributions.php
includes/specials/SpecialDisambiguations.php
includes/specials/SpecialExport.php
includes/specials/SpecialImport.php
includes/specials/SpecialLinkSearch.php
includes/specials/SpecialListfiles.php
includes/specials/SpecialListusers.php
includes/specials/SpecialMovepage.php
includes/specials/SpecialNewpages.php
includes/specials/SpecialProtectedpages.php
includes/specials/SpecialProtectedtitles.php
includes/specials/SpecialRecentchanges.php
includes/specials/SpecialRevisiondelete.php
includes/specials/SpecialSearch.php
includes/specials/SpecialSpecialpages.php
includes/specials/SpecialStatistics.php
includes/specials/SpecialUncategorizedcategories.php
includes/specials/SpecialUndelete.php
includes/specials/SpecialUpload.php
includes/specials/SpecialUserlogin.php
includes/specials/SpecialUserrights.php
includes/specials/SpecialVersion.php
includes/specials/SpecialWatchlist.php

index 38b4a82..75e55f1 100644 (file)
@@ -193,7 +193,7 @@ class CliInstaller extends Installer {
 
        public function envCheckPath( ) {
                if ( !$this->specifiedScriptPath ) {
-                       $this->showMessage( 'config-no-cli-uri', $this->getVar("wgScriptPath") );
+                       $this->showMessage( 'config-no-cli-uri', $this->getVar( "wgScriptPath" ) );
                }
                return parent::envCheckPath();
        }
index f27165d..10d23fb 100644 (file)
@@ -240,7 +240,7 @@ abstract class DatabaseInstaller {
                if ( $status->isOK() ) {
                        $status->value->setSchemaVars( $this->getSchemaVars() );
                } else {
-                       throw new MWException( __METHOD__.': unexpected DB connection error' );
+                       throw new MWException( __METHOD__ . ': unexpected DB connection error' );
                }
        }
 
@@ -252,7 +252,7 @@ abstract class DatabaseInstaller {
        public function enableLB() {
                $status = $this->getConnection();
                if ( !$status->isOK() ) {
-                       throw new MWException( __METHOD__.': unexpected DB connection error' );
+                       throw new MWException( __METHOD__ . ': unexpected DB connection error' );
                }
                LBFactory::setInstance( new LBFactory_Single( array(
                        'connection' => $status->value ) ) );
index 9caf168..746cd12 100644 (file)
@@ -451,7 +451,7 @@ abstract class DatabaseUpdater {
                $key = "updatelist-$version-" . time();
                $this->db->insert( 'updatelog',
                        array( 'ul_key' => $key, 'ul_value' => serialize( $updates ) ),
-                        __METHOD__ );
+                       __METHOD__ );
                $this->db->setFlag( DBO_DDLMODE );
        }
 
@@ -633,7 +633,7 @@ abstract class DatabaseUpdater {
                } else {
                        $this->db->sourceFile( $path );
                }
-               $this->output( "done.\n" );
+               $this->output( "done.\n" );
                return true;
        }
 
index da351ca..325f894 100644 (file)
@@ -488,7 +488,7 @@ abstract class Installer {
                if( !$_lsExists ) {
                        return false;
                }
-               unset($_lsExists);
+               unset( $_lsExists );
 
                require( "$IP/includes/DefaultSettings.php" );
                require( "$IP/LocalSettings.php" );
@@ -1073,18 +1073,18 @@ abstract class Installer {
         * @return string
         */
        protected function unicodeChar( $c ) {
-               $c = hexdec($c);
-               if ($c <= 0x7F) {
-                       return chr($c);
-               } elseif ($c <= 0x7FF) {
-                       return chr(0xC0 | $c >> 6) . chr(0x80 | $c & 0x3F);
-               } elseif ($c <= 0xFFFF) {
-                       return chr(0xE0 | $c >> 12) . chr(0x80 | $c >> 6 & 0x3F)
-                               . chr(0x80 | $c & 0x3F);
-               } elseif ($c <= 0x10FFFF) {
-                       return chr(0xF0 | $c >> 18) . chr(0x80 | $c >> 12 & 0x3F)
-                               . chr(0x80 | $c >> 6 & 0x3F)
-                               . chr(0x80 | $c & 0x3F);
+               $c = hexdec( $c );
+               if ( $c <= 0x7F ) {
+                       return chr( $c );
+               } elseif ( $c <= 0x7FF ) {
+                       return chr( 0xC0 | $c >> 6 ) . chr( 0x80 | $c & 0x3F );
+               } elseif ( $c <= 0xFFFF ) {
+                       return chr( 0xE0 | $c >> 12 ) . chr( 0x80 | $c >> 6 & 0x3F )
+                               . chr( 0x80 | $c & 0x3F );
+               } elseif ( $c <= 0x10FFFF ) {
+                       return chr( 0xF0 | $c >> 18 ) . chr( 0x80 | $c >> 12 & 0x3F )
+                               . chr( 0x80 | $c >> 6 & 0x3F )
+                               . chr( 0x80 | $c & 0x3F );
                } else {
                        return false;
                }
@@ -1105,8 +1105,8 @@ abstract class Installer {
                 * Note that we use the hex representation to create the code
                 * points in order to avoid any Unicode-destroying during transit.
                 */
-               $not_normal_c = $this->unicodeChar("FA6C");
-               $normal_c = $this->unicodeChar("242EE");
+               $not_normal_c = $this->unicodeChar( "FA6C" );
+               $normal_c = $this->unicodeChar( "242EE" );
 
                $useNormalizer = 'php';
                $needsUpdate = false;
index 94c38c4..4eb2d39 100644 (file)
@@ -516,7 +516,8 @@ class MysqlInstaller extends DatabaseInstaller {
                }
 
                if( $tryToCreate ) {
-                       $createHostList = array($server,
+                       $createHostList = array(
+                               $server,
                                'localhost',
                                'localhost.localdomain',
                                '%'
index da638de..a19637e 100644 (file)
@@ -329,7 +329,7 @@ class MysqlUpdater extends DatabaseUpdater {
                }
 
                if( $this->applyPatch( 'patch-fix-il_from.sql', false, "Fixing ancient broken imagelinks table." ) ) {
-                       $this->output("NOTE: you will have to run maintenance/refreshLinks.php after this." );
+                       $this->output( "NOTE: you will have to run maintenance/refreshLinks.php after this." );
                }
        }
 
index 845816e..4c72a8f 100644 (file)
@@ -119,7 +119,7 @@ class OracleInstaller extends DatabaseInstaller {
                                        return $status;
                                }
                                if ( !$this->getVar( '_CreateDBAccount' ) ) {
-                                       $status->fatal('config-db-sys-create-oracle');
+                                       $status->fatal( 'config-db-sys-create-oracle' );
                                }
                        } else {
                                return $status;
@@ -241,7 +241,7 @@ class OracleInstaller extends DatabaseInstaller {
                        $status->fatal( 'config-db-sys-user-exists-oracle', $this->getVar( 'wgDBuser' ) );
                }
 
-               if ($status->isOK()) {
+               if ( $status->isOK() ) {
                        // user created or already existing, switching back to a normal connection
                        // as the new user has all needed privileges to setup the rest of the schema
                        // i will be using that user as _InstallUser from this point on
index 8f43a6d..cafe8cd 100644 (file)
@@ -163,7 +163,7 @@ class OracleUpdater extends DatabaseUpdater {
         * converted to NULL in Oracle
         */
        protected function doRemoveNotNullEmptyDefaults() {
-               $meta = $this->db->fieldInfo( 'categorylinks' , 'cl_sortkey_prefix' );
+               $meta = $this->db->fieldInfo( 'categorylinks', 'cl_sortkey_prefix' );
                if ( $meta->isNullable() ) {
                        return;
                }
@@ -171,7 +171,7 @@ class OracleUpdater extends DatabaseUpdater {
        }
 
        protected function doRemoveNotNullEmptyDefaults2() {
-               $meta = $this->db->fieldInfo( 'ipblocks' , 'ipb_by_text' );
+               $meta = $this->db->fieldInfo( 'ipblocks', 'ipb_by_text' );
                if ( $meta->isNullable() ) {
                        return;
                }
index 3b1f7d0..643459f 100644 (file)
@@ -239,62 +239,62 @@ class PostgresUpdater extends DatabaseUpdater {
                        array( 'addPgIndex', 'filearchive',   'fa_sha1',                '(fa_sha1)' ),
 
                        array( 'checkIndex', 'pagelink_unique', array(
-                               array('pl_from', 'int4_ops', 'btree', 0),
-                               array('pl_namespace', 'int2_ops', 'btree', 0),
-                               array('pl_title', 'text_ops', 'btree', 0),
+                               array( 'pl_from', 'int4_ops', 'btree', 0 ),
+                               array( 'pl_namespace', 'int2_ops', 'btree', 0 ),
+                               array( 'pl_title', 'text_ops', 'btree', 0 ),
                        ),
                        'CREATE UNIQUE INDEX pagelink_unique ON pagelinks (pl_from,pl_namespace,pl_title)' ),
                        array( 'checkIndex', 'cl_sortkey', array(
-                               array('cl_to', 'text_ops', 'btree', 0),
-                               array('cl_sortkey', 'text_ops', 'btree', 0),
-                               array('cl_from', 'int4_ops', 'btree', 0),
+                               array( 'cl_to', 'text_ops', 'btree', 0 ),
+                               array( 'cl_sortkey', 'text_ops', 'btree', 0 ),
+                               array( 'cl_from', 'int4_ops', 'btree', 0 ),
                        ),
                        'CREATE INDEX cl_sortkey ON "categorylinks" USING "btree" ("cl_to", "cl_sortkey", "cl_from")' ),
                        array( 'checkIndex', 'logging_times', array(
-                               array('log_timestamp', 'timestamptz_ops', 'btree', 0),
+                               array( 'log_timestamp', 'timestamptz_ops', 'btree', 0 ),
                        ),
                        'CREATE INDEX "logging_times" ON "logging" USING "btree" ("log_timestamp")' ),
                        array( 'dropIndex', 'oldimage', 'oi_name' ),
                        array( 'checkIndex', 'oi_name_archive_name', array(
-                               array('oi_name', 'text_ops', 'btree', 0),
-                               array('oi_archive_name', 'text_ops', 'btree', 0),
+                               array( 'oi_name', 'text_ops', 'btree', 0 ),
+                               array( 'oi_archive_name', 'text_ops', 'btree', 0 ),
                        ),
                        'CREATE INDEX "oi_name_archive_name" ON "oldimage" USING "btree" ("oi_name", "oi_archive_name")' ),
                        array( 'checkIndex', 'oi_name_timestamp', array(
-                               array('oi_name', 'text_ops', 'btree', 0),
-                               array('oi_timestamp', 'timestamptz_ops', 'btree', 0),
+                               array( 'oi_name', 'text_ops', 'btree', 0 ),
+                               array( 'oi_timestamp', 'timestamptz_ops', 'btree', 0 ),
                        ),
                        'CREATE INDEX "oi_name_timestamp" ON "oldimage" USING "btree" ("oi_name", "oi_timestamp")' ),
                        array( 'checkIndex', 'page_main_title', array(
-                               array('page_title', 'text_pattern_ops', 'btree', 0),
+                               array( 'page_title', 'text_pattern_ops', 'btree', 0 ),
                        ),
                        'CREATE INDEX "page_main_title" ON "page" USING "btree" ("page_title" "text_pattern_ops") WHERE ("page_namespace" = 0)' ),
                        array( 'checkIndex', 'page_mediawiki_title', array(
-                               array('page_title', 'text_pattern_ops', 'btree', 0),
+                               array( 'page_title', 'text_pattern_ops', 'btree', 0 ),
                        ),
                        'CREATE INDEX "page_mediawiki_title" ON "page" USING "btree" ("page_title" "text_pattern_ops") WHERE ("page_namespace" = 8)' ),
                        array( 'checkIndex', 'page_project_title', array(
-                               array('page_title', 'text_pattern_ops', 'btree', 0),
+                               array( 'page_title', 'text_pattern_ops', 'btree', 0 ),
                        ),
                        'CREATE INDEX "page_project_title" ON "page" USING "btree" ("page_title" "text_pattern_ops") WHERE ("page_namespace" = 4)' ),
                        array( 'checkIndex', 'page_talk_title', array(
-                               array('page_title', 'text_pattern_ops', 'btree', 0),
+                               array( 'page_title', 'text_pattern_ops', 'btree', 0 ),
                        ),
                        'CREATE INDEX "page_talk_title" ON "page" USING "btree" ("page_title" "text_pattern_ops") WHERE ("page_namespace" = 1)' ),
                        array( 'checkIndex', 'page_user_title', array(
-                               array('page_title', 'text_pattern_ops', 'btree', 0),
+                               array( 'page_title', 'text_pattern_ops', 'btree', 0 ),
                        ),
                        'CREATE INDEX "page_user_title" ON "page" USING "btree" ("page_title" "text_pattern_ops") WHERE ("page_namespace" = 2)' ),
                        array( 'checkIndex', 'page_utalk_title', array(
-                               array('page_title', 'text_pattern_ops', 'btree', 0),
+                               array( 'page_title', 'text_pattern_ops', 'btree', 0 ),
                        ),
                        'CREATE INDEX "page_utalk_title" ON "page" USING "btree" ("page_title" "text_pattern_ops") WHERE ("page_namespace" = 3)' ),
                        array( 'checkIndex', 'ts2_page_text', array(
-                               array('textvector', 'tsvector_ops', 'gist', 0),
+                               array( 'textvector', 'tsvector_ops', 'gist', 0 ),
                        ),
                        'CREATE INDEX "ts2_page_text" ON "pagecontent" USING "gist" ("textvector")' ),
                        array( 'checkIndex', 'ts2_page_title', array(
-                               array('titlevector', 'tsvector_ops', 'gist', 0),
+                               array( 'titlevector', 'tsvector_ops', 'gist', 0 ),
                        ),
                        'CREATE INDEX "ts2_page_title" ON "page" USING "gist" ("titlevector")' ),
 
@@ -303,10 +303,10 @@ class PostgresUpdater extends DatabaseUpdater {
                        array( 'checkRevUserFkey' ),
                        array( 'dropIndex', 'ipblocks', 'ipb_address'),
                        array( 'checkIndex', 'ipb_address_unique', array(
-                               array('ipb_address', 'text_ops', 'btree', 0),
-                               array('ipb_user',    'int4_ops', 'btree', 0),
-                               array('ipb_auto',    'int2_ops', 'btree', 0),
-                               array('ipb_anon_only', 'int2_ops', 'btree', 0),
+                               array( 'ipb_address', 'text_ops', 'btree', 0 ),
+                               array( 'ipb_user',    'int4_ops', 'btree', 0 ),
+                               array( 'ipb_auto',    'int2_ops', 'btree', 0 ),
+                               array( 'ipb_anon_only', 'int2_ops', 'btree', 0 ),
                        ),
                        'CREATE UNIQUE INDEX ipb_address_unique ON ipblocks (ipb_address,ipb_user,ipb_auto,ipb_anon_only)' ),
 
@@ -509,7 +509,7 @@ END;
                        $this->output( "Creating sequence $ns\n" );
                        $this->db->query( "CREATE SEQUENCE $ns" );
                        if( $pkey !== false ) {
-                               $this->setDefault( $table,  $pkey, '"nextval"(\'"' . $ns . '"\'::"regclass")' );
+                               $this->setDefault( $table, $pkey, '"nextval"(\'"' . $ns . '"\'::"regclass")' );
                        }
                }
        }
index 8cee4b2..c080871 100644 (file)
@@ -933,7 +933,7 @@ class WebInstaller extends Installer {
         * @return string
         */
        public function getRadioSet( $params ) {
-               if ( !isset( $params['controlName']  ) ) {
+               if ( !isset( $params['controlName'] ) ) {
                        $params['controlName'] = 'config_' . $params['var'];
                }
 
@@ -1096,7 +1096,7 @@ class WebInstaller extends Installer {
                } elseif ( !empty( $_SERVER['SCRIPT_NAME'] ) ) {
                        $path = $_SERVER['SCRIPT_NAME'];
                }
-               if ($path !== false) {
+               if ( $path !== false ) {
                        $uri = preg_replace( '{^(.*)/(mw-)?config.*$}', '$1', $path );
                        $this->setVar( 'wgScriptPath', $uri );
                } else {
index f3166c2..42f451f 100644 (file)
@@ -219,7 +219,7 @@ class WebInstallerOutput {
                $dbTypes = $this->parent->getDBTypes();
 
                $this->parent->request->response()->header( 'Content-Type: text/html; charset=utf-8' );
-               if (!$this->allowFrames) {
+               if ( !$this->allowFrames ) {
                        $this->parent->request->response()->header( 'X-Frame-Options: DENY' );
                }
                if ( $this->redirectTarget ) {
@@ -239,7 +239,7 @@ class WebInstallerOutput {
        <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
        <title><?php $this->outputTitle(); ?></title>
        <?php echo $this->getCssUrl() . "\n"; ?>
-       <?php echo Html::inlineScript(  "var dbTypes = " . Xml::encodeJsVar( $dbTypes ) ) . "\n"; ?>
+       <?php echo Html::inlineScript( "var dbTypes = " . Xml::encodeJsVar( $dbTypes ) ) . "\n"; ?>
        <?php echo $this->getJQuery() . "\n"; ?>
        <?php echo Html::linkedScript( '../skins/common/config.js' ) . "\n"; ?>
 </head>
index 572360a..07047f2 100644 (file)
@@ -369,7 +369,7 @@ class WebInstaller_ExistingWiki extends WebInstallerPage {
 
                // Set the relevant variables from LocalSettings.php
                $requiredVars = array( 'wgDBtype' );
-               $status = $this->importVariables( $requiredVars , $vars );
+               $status = $this->importVariables( $requiredVars, $vars );
                $installer = $this->parent->getDBInstaller();
                $status->merge( $this->importVariables( $installer->getGlobalNames(), $vars ) );
                if ( !$status->isOK() ) {
@@ -645,7 +645,7 @@ class WebInstaller_Name extends WebInstallerPage {
                        $this->parent->getTextBox( array(
                                'var' => 'wgSitename',
                                'label' => 'config-site-name',
-                         'help' => $this->parent->getHelpBox( 'config-site-name-help' )
+                               'help' => $this->parent->getHelpBox( 'config-site-name-help' )
                        ) ) .
                        $this->parent->getRadioSet( array(
                                'var' => '_NamespaceType',
@@ -955,7 +955,7 @@ class WebInstaller_Options extends WebInstallerPage {
 
                // We'll hide/show this on demand when the value changes, see config.js.
                $cacheval = $this->getVar( 'wgMainCacheType' );
-               if (!$cacheval) {
+               if ( !$cacheval ) {
                        // We need to set a default here; but don't hardcode it
                        // or we lose it every time we reload the page for validation
                        // or going back!
@@ -1025,7 +1025,7 @@ class WebInstaller_Options extends WebInstallerPage {
                } else {
                        $iframeAttribs['src'] = $this->getCCPartnerUrl();
                }
-               $wrapperStyle = ($this->getVar('_LicenseCode') == 'cc-choose') ? '' : 'display: none';
+               $wrapperStyle = ($this->getVar( '_LicenseCode' ) == 'cc-choose') ? '' : 'display: none';
 
                return
                        "<div class=\"config-cc-wrapper\" id=\"config-cc-wrapper\" style=\"$wrapperStyle\">\n" .
@@ -1155,12 +1155,12 @@ class WebInstaller_Install extends WebInstallerPage {
                        return 'continue';
                } elseif( $this->parent->request->wasPosted() ) {
                        $this->startForm();
-                       $this->addHTML("<ul>");
+                       $this->addHTML( "<ul>" );
                        $results = $this->parent->performInstallation(
                                array( $this, 'startStage'),
                                array( $this, 'endStage' )
                        );
-                       $this->addHTML("</ul>");
+                       $this->addHTML( "</ul>" );
                        // PerformInstallation bails on a fatal, so make sure the last item
                        // completed before giving 'next.' Likewise, only provide back on failure
                        $lastStep = end( $results );
@@ -1287,8 +1287,8 @@ class WebInstaller_ReleaseNotes extends WebInstaller_Document {
        protected function getFileName() {
                global $wgVersion;
 
-               if(preg_match( '/^(\d+)\.(\d+).*/i', $wgVersion, $result ) ) {
-                       throw new MWException('Variable $wgVersion has an invalid value.');
+               if( !preg_match( '/^(\d+)\.(\d+).*/i', $wgVersion, $result ) ) {
+                       throw new MWException( 'Variable $wgVersion has an invalid value.' );
                }
 
                return 'RELEASE-NOTES-' . $result[1] . '.' . $result[2];
index b8a1bc2..960668f 100644 (file)
@@ -39,13 +39,13 @@ class EhcacheBagOStuff extends BagOStuff {
         */
        function __construct( $params ) {
                if ( !defined( 'CURLOPT_TIMEOUT_MS' ) ) {
-                       throw new MWException( __CLASS__.' requires curl version 7.16.2 or later.' );
+                       throw new MWException( __CLASS__ . ' requires curl version 7.16.2 or later.' );
                }
                if ( !extension_loaded( 'zlib' ) ) {
-                       throw new MWException( __CLASS__.' requires the zlib extension' );
+                       throw new MWException( __CLASS__ . ' requires the zlib extension' );
                }
                if ( !isset( $params['servers'] ) ) {
-                       throw new MWException( __METHOD__.': servers parameter is required' );
+                       throw new MWException( __METHOD__ . ': servers parameter is required' );
                }
                $this->servers = $params['servers'];
                $this->cacheName = isset( $params['cache'] ) ? $params['cache'] : 'mw';
@@ -76,7 +76,7 @@ class EhcacheBagOStuff extends BagOStuff {
                        return false;
                }
                if ( $response['http_code'] >= 300 ) {
-                       wfDebug( __METHOD__.": GET failure, got HTTP {$response['http_code']}\n" );
+                       wfDebug( __METHOD__ . ": GET failure, got HTTP {$response['http_code']}\n" );
                        wfProfileOut( __METHOD__ );
                        return false;
                }
@@ -85,7 +85,7 @@ class EhcacheBagOStuff extends BagOStuff {
                if ( $type == 'application/vnd.php.serialized+deflate' ) {
                        $body = gzinflate( $body );
                        if ( !$body ) {
-                               wfDebug( __METHOD__.": error inflating $key\n" );
+                               wfDebug( __METHOD__ . ": error inflating $key\n" );
                                wfProfileOut( __METHOD__ );
                                return false;
                        }
@@ -93,7 +93,7 @@ class EhcacheBagOStuff extends BagOStuff {
                } elseif ( $type == 'application/vnd.php.serialized' ) {
                        $data = unserialize( $body );
                } else {
-                       wfDebug( __METHOD__.": unknown content type \"$type\"\n" );
+                       wfDebug( __METHOD__ . ": unknown content type \"$type\"\n" );
                        wfProfileOut( __METHOD__ );
                        return false;
                }
@@ -127,7 +127,7 @@ class EhcacheBagOStuff extends BagOStuff {
                if ( $code == 404 ) {
                        // Maybe the cache does not exist yet, let's try creating it
                        if ( !$this->createCache( $key ) ) {
-                               wfDebug( __METHOD__.": cache creation failed\n" );
+                               wfDebug( __METHOD__ . ": cache creation failed\n" );
                                wfProfileOut( __METHOD__ );
                                return false;
                        }
@@ -136,9 +136,9 @@ class EhcacheBagOStuff extends BagOStuff {
 
                $result = false;
                if ( !$code ) {
-                       wfDebug( __METHOD__.": PUT failure for key $key\n" );
+                       wfDebug( __METHOD__ . ": PUT failure for key $key\n" );
                } elseif ( $code >= 300 ) {
-                       wfDebug( __METHOD__.": PUT failure for key $key: HTTP $code\n" );
+                       wfDebug( __METHOD__ . ": PUT failure for key $key: HTTP $code\n" );
                } else {
                        $result = true;
                }
@@ -172,7 +172,7 @@ class EhcacheBagOStuff extends BagOStuff {
                        array( CURLOPT_CUSTOMREQUEST => 'DELETE' ) );
                $code = isset( $response['http_code'] ) ? $response['http_code'] : 0;
                if ( !$response || ( $code != 404 && $code >= 300 ) ) {
-                       wfDebug( __METHOD__.": DELETE failure for key $key\n" );
+                       wfDebug( __METHOD__ . ": DELETE failure for key $key\n" );
                        $result = false;
                } else {
                        $result = true;
@@ -256,7 +256,7 @@ class EhcacheBagOStuff extends BagOStuff {
         * @return bool
         */
        protected function createCache( $key ) {
-               wfDebug( __METHOD__.": creating cache for $key\n" );
+               wfDebug( __METHOD__ . ": creating cache for $key\n" );
                $response = $this->doCacheRequest( $key,
                        array(
                                CURLOPT_POST => 1,
@@ -264,7 +264,7 @@ class EhcacheBagOStuff extends BagOStuff {
                                CURLOPT_POSTFIELDS => '',
                        ) );
                if ( !$response ) {
-                       wfDebug( __CLASS__.": failed to create cache for $key\n" );
+                       wfDebug( __CLASS__ . ": failed to create cache for $key\n" );
                        return false;
                }
                return ( $response['http_code'] == 201 /* created */
@@ -304,7 +304,7 @@ class EhcacheBagOStuff extends BagOStuff {
        protected function doRequest( $curl, $url, $curlOptions = array() ) {
                if ( array_diff_key( $curlOptions, $this->curlOptions ) ) {
                        // var_dump( array_diff_key( $curlOptions, $this->curlOptions ) );
-                       throw new MWException( __METHOD__.": to prevent options set in one doRequest() " .
+                       throw new MWException( __METHOD__ . ": to prevent options set in one doRequest() " .
                                "call from affecting subsequent doRequest() calls, only options listed " .
                                "in \$this->curlOptions may be specified in the \$curlOptions parameter." );
                }
@@ -314,7 +314,7 @@ class EhcacheBagOStuff extends BagOStuff {
                curl_setopt_array( $curl, $curlOptions );
                $result = curl_exec( $curl );
                if ( $result === false ) {
-                       wfDebug( __CLASS__.": curl error: " . curl_error( $curl ) . "\n" );
+                       wfDebug( __CLASS__ . ": curl error: " . curl_error( $curl ) . "\n" );
                        return false;
                }
                $info = curl_getinfo( $curl );
index faa676d..2342d63 100644 (file)
@@ -991,7 +991,7 @@ class MWMemcached {
                $len = strlen( $val );
 
                if ( $this->_have_zlib && $this->_compress_enable &&
-                        $this->_compress_threshold && $len >= $this->_compress_threshold )
+                       $this->_compress_threshold && $len >= $this->_compress_threshold )
                {
                        $c_val = gzcompress( $val, 9 );
                        $c_len = strlen( $c_val );
index 0fc117a..bae1b75 100644 (file)
@@ -127,7 +127,7 @@ class SqlBagOStuff extends BagOStuff {
                                $info = $this->serverInfos[$serverIndex];
                                $type = isset( $info['type'] ) ? $info['type'] : 'mysql';
                                $host = isset( $info['host'] ) ? $info['host'] : '[unknown]';
-                               wfDebug( __CLASS__.": connecting to $host\n" );
+                               wfDebug( __CLASS__ . ": connecting to $host\n" );
                                $db = DatabaseBase::factory( $type, $info );
                                $db->clearFlag( DBO_TRX );
                        } else {
@@ -659,12 +659,12 @@ class SqlBagOStuff extends BagOStuff {
                                unset( $this->connFailureTimes[$serverIndex] );
                                unset( $this->connFailureErrors[$serverIndex] );
                        } else {
-                               wfDebug( __METHOD__.": Server #$serverIndex already down\n" );
+                               wfDebug( __METHOD__ . ": Server #$serverIndex already down\n" );
                                return;
                        }
                }
                $now = time();
-               wfDebug( __METHOD__.": Server #$serverIndex down until " . ( $now + 60 ) . "\n" );
+               wfDebug( __METHOD__ . ": Server #$serverIndex down until " . ( $now + 60 ) . "\n" );
                $this->connFailureTimes[$serverIndex] = $now;
                $this->connFailureErrors[$serverIndex] = $exception;
        }
index 401e65d..eeda739 100644 (file)
@@ -180,7 +180,7 @@ class SpecialAllpages extends IncludableSpecialPage {
                $where = array( 'page_namespace' => $namespace );
 
                if ( $hideredirects ) {
-                       $where[ 'page_is_redirect' ] = 0;
+                       $where['page_is_redirect'] = 0;
                }
 
                $from = Title::makeTitleSafe( $namespace, $from );
@@ -250,7 +250,7 @@ class SpecialAllpages extends IncludableSpecialPage {
                // If there are only two or less sections, don't even display them.
                // Instead, display the first section directly.
                if( count( $lines ) <= 2 ) {
-                       if( !empty($lines) ) {
+                       if( !empty( $lines ) ) {
                                $this->showChunk( $namespace, $from, $to, $hideredirects );
                        } else {
                                $output->addHTML( $this->namespaceForm( $namespace, $from, $to, $hideredirects ) );
@@ -312,7 +312,7 @@ class SpecialAllpages extends IncludableSpecialPage {
 
                $queryhideredirects = array();
                if ( $hideredirects ) {
-                       $queryhideredirects[ 'hideredirects' ] = 1;
+                       $queryhideredirects['hideredirects'] = 1;
                }
 
                $special = $this->getTitle();
@@ -357,7 +357,7 @@ class SpecialAllpages extends IncludableSpecialPage {
                        );
 
                        if ( $hideredirects ) {
-                               $conds[ 'page_is_redirect' ] = 0;
+                               $conds['page_is_redirect'] = 0;
                        }
 
                        if( $toKey !== "" ) {
index 42d3377..bfa2f95 100644 (file)
@@ -33,6 +33,6 @@ class SpecialBlankpage extends UnlistedSpecialPage {
        }
        public function execute( $par ) {
                $this->setHeaders();
-               $this->getOutput()->addWikiMsg('intentionallyblankpage');
+               $this->getOutput()->addWikiMsg( 'intentionallyblankpage' );
        }
 }
index b71588d..bbb3213 100644 (file)
@@ -62,7 +62,7 @@ class SpecialBlock extends FormSpecialPage {
         * @throws ErrorPageError
         */
        protected function checkExecutePermissions( User $user ) {
-                parent::checkExecutePermissions( $user );
+               parent::checkExecutePermissions( $user );
 
                # bug 15810: blocked admins should have limited access here
                $status = self::checkUnblockSelf( $this->target, $user );
@@ -239,7 +239,7 @@ class SpecialBlock extends FormSpecialPage {
 
                if ( $block instanceof Block && !$block->mAuto # The block exists and isn't an autoblock
                        && ( $this->type != Block::TYPE_RANGE # The block isn't a rangeblock
-                         || $block->getTarget() == $this->target ) # or if it is, the range is what we're about to block
+                               || $block->getTarget() == $this->target ) # or if it is, the range is what we're about to block
                        )
                {
                        $fields['HardBlock']['default'] = $block->isHardblock();
@@ -769,7 +769,7 @@ class SpecialBlock extends FormSpecialPage {
                        $logParams
                );
                # Relate log ID to block IDs (bug 25763)
-               $blockIds = array_merge( array( $status['id'] ), $status['autoIds']  );
+               $blockIds = array_merge( array( $status['id'] ), $status['autoIds'] );
                $log->addRelations( 'ipb_id', $blockIds, $log_id );
 
                # Report to the user
index d1afe58..56b9b00 100644 (file)
@@ -472,7 +472,7 @@ class HTMLBlockedUsersItemSelect extends HTMLSelectField {
                        // This adds the explicitly requested limit value to the drop-down,
                        // then makes sure it's sorted correctly so when we output the list
                        // later, the custom option doesn't just show up last.
-                       $this->mParams['options'][ $this->mParent->getLanguage()->formatNum( $value ) ] = intval($value);
+                       $this->mParams['options'][$this->mParent->getLanguage()->formatNum( $value )] = intval( $value );
                        asort( $this->mParams['options'] );
                }
 
index 6d27c1b..255b1b6 100644 (file)
@@ -62,7 +62,7 @@ class SpecialBookSources extends SpecialPage {
        }
 
        /**
-        * Returns whether a given ISBN (10 or 13) is valid.  True indicates validity.
+        * Returns whether a given ISBN (10 or 13) is valid. True indicates validity.
         * @param $isbn string ISBN passed for check
         * @return bool
         */
@@ -71,7 +71,7 @@ class SpecialBookSources extends SpecialPage {
                $sum = 0;
                if( strlen( $isbn ) == 13 ) {
                        for( $i = 0; $i < 12; $i++ ) {
-                               if($i % 2 == 0) {
+                               if( $i % 2 == 0 ) {
                                        $sum += $isbn[$i];
                                } else {
                                        $sum += 3 * $isbn[$i];
@@ -79,19 +79,19 @@ class SpecialBookSources extends SpecialPage {
                        }
 
                        $check = (10 - ($sum % 10)) % 10;
-                       if ($check == $isbn[12]) {
+                       if ( $check == $isbn[12] ) {
                                return true;
                        }
                } elseif( strlen( $isbn ) == 10 ) {
-                       for($i = 0; $i < 9; $i++) {
+                       for( $i = 0; $i < 9; $i++ ) {
                                $sum += $isbn[$i] * ($i + 1);
                        }
 
                        $check = $sum % 11;
-                       if($check == 10) {
+                       if( $check == 10 ) {
                                $check = "X";
                        }
-                       if($check == $isbn[9]) {
+                       if( $check == $isbn[9] ) {
                                return true;
                        }
                }
index 1232e3f..44388c4 100644 (file)
@@ -72,7 +72,7 @@ class CategoryPager extends AlphabeticPager {
        function getQueryInfo() {
                return array(
                        'tables' => array( 'category' ),
-                       'fields' => array( 'cat_title','cat_pages' ),
+                       'fields' => array( 'cat_title', 'cat_pages' ),
                        'conds' => array( 'cat_pages > 0' ),
                        'options' => array( 'USE INDEX' => 'cat_title' ),
                );
@@ -112,7 +112,7 @@ class CategoryPager extends AlphabeticPager {
                return parent::getBody();
        }
 
-       function formatRow($result) {
+       function formatRow( $result ) {
                $title = Title::makeTitle( NS_CATEGORY, $result->cat_title );
                $titleText = Linker::link( $title, htmlspecialchars( $title->getText() ) );
                $count = $this->msg( 'nmembers' )->numParams( $result->cat_pages )->escaped();
index 54ec07d..af4d4fb 100644 (file)
@@ -360,7 +360,7 @@ class SpecialContributions extends SpecialPage {
                if ( !isset( $this->opts['target'] ) ) {
                        $this->opts['target'] = '';
                } else {
-                       $this->opts['target'] = str_replace( '_' , ' ' , $this->opts['target'] );
+                       $this->opts['target'] = str_replace( '_', ' ', $this->opts['target'] );
                }
 
                if ( !isset( $this->opts['namespace'] ) ) {
@@ -424,7 +424,7 @@ class SpecialContributions extends SpecialPage {
                        Xml::radioLabel(
                                $this->msg( 'sp-contributions-newbies' )->text(),
                                'contribs',
-                               'newbie' ,
+                               'newbie',
                                'newbie',
                                $this->opts['contribs'] == 'newbie',
                                array( 'class' => 'mw-input' )
index 48180a7..a9c554a 100644 (file)
@@ -59,20 +59,20 @@ class DisambiguationsPage extends QueryPage {
                        if( $dp->getNamespace() != NS_TEMPLATE ) {
                                # @todo FIXME: We assume the disambiguation message is a template but
                                # the page can potentially be from another namespace :/
-                               wfDebug("Mediawiki:disambiguationspage message does not refer to a template!\n");
+                               wfDebug( "Mediawiki:disambiguationspage message does not refer to a template!\n" );
                        }
                        $linkBatch->addObj( $dp );
                } else {
                                # Get all the templates linked from the Mediawiki:Disambiguationspage
                                $disPageObj = Title::makeTitleSafe( NS_MEDIAWIKI, 'disambiguationspage' );
                                $res = $dbr->select(
-                                       array('pagelinks', 'page'),
+                                       array( 'pagelinks', 'page' ),
                                        'pl_title',
-                                       array('page_id = pl_from',
+                                       array( 'page_id = pl_from',
                                                'pl_namespace' => NS_TEMPLATE,
                                                'page_namespace' => $disPageObj->getNamespace(),
-                                               'page_title' => $disPageObj->getDBkey()),
-                                       __METHOD__ );
+                                               'page_title' => $disPageObj->getDBkey()
+                                       ), __METHOD__ );
 
                                foreach ( $res as $row ) {
                                        $linkBatch->addObj( Title::makeTitle( NS_TEMPLATE, $row->pl_title ));
index 18dde20..9eb555a 100644 (file)
@@ -124,7 +124,7 @@ class SpecialExport extends SpecialPage {
                        if ( $this->curonly ) {
                                $history = WikiExporter::CURRENT;
                        } elseif ( !$historyCheck ) {
-                               if ( $limit > 0 && ($wgExportMaxHistory == 0 || $limit < $wgExportMaxHistory ) ) {
+                               if ( $limit > 0 && ( $wgExportMaxHistory == 0 || $limit < $wgExportMaxHistory ) ) {
                                        $history['limit'] = $limit;
                                }
                                if ( !is_null( $offset ) ) {
@@ -339,7 +339,7 @@ class SpecialExport extends SpecialPage {
 
                        // This might take a while... :D
                        wfSuppressWarnings();
-                       set_time_limit(0);
+                       set_time_limit( 0 );
                        wfRestoreWarnings();
                }
 
@@ -405,7 +405,7 @@ class SpecialExport extends SpecialPage {
 
                foreach ( $res as $row ) {
                        $n = $row->page_title;
-                       if ($row->page_namespace) {
+                       if ( $row->page_namespace ) {
                                $ns = $wgContLang->getNsText( $row->page_namespace );
                                $n = $ns . ':' . $n;
                        }
index 9fb0f9e..16772ec 100644 (file)
@@ -353,7 +353,7 @@ class ImportReporter extends ContextSource {
        private $mOriginalPageOutCallback = null;
        private $mLogItemCount = 0;
 
-       function __construct( $importer, $upload, $interwiki , $reason=false ) {
+       function __construct( $importer, $upload, $interwiki, $reason = false ) {
                $this->mOriginalPageOutCallback =
                                $importer->setPageOutCallback( array( $this, 'reportPage' ) );
                $this->mOriginalLogCallback =
index 9a224b6..f5fa697 100644 (file)
@@ -64,15 +64,15 @@ class LinkSearchPage extends QueryPage {
 
                $target2 = $target;
                $protocol = '';
-               $pr_sl = strpos($target2, '//' );
-               $pr_cl = strpos($target2, ':' );
+               $pr_sl = strpos( $target2, '//' );
+               $pr_cl = strpos( $target2, ':' );
                if ( $pr_sl ) {
                        // For protocols with '//'
-                       $protocol = substr( $target2, 0 , $pr_sl+2 );
-                       $target2 = substr( $target2, $pr_sl+2 );
+                       $protocol = substr( $target2, 0, $pr_sl + 2 );
+                       $target2 = substr( $target2, $pr_sl + 2 );
                } elseif ( !$pr_sl && $pr_cl ) {
                        // For protocols without '//' like 'mailto:'
-                       $protocol = substr( $target2, 0 , $pr_cl+1 );
+                       $protocol = substr( $target2, 0, $pr_cl + 1 );
                        $target2 = substr( $target2, $pr_cl+1 );
                } elseif ( $protocol == '' && $target2 != '' ) {
                        // default
@@ -138,10 +138,10 @@ class LinkSearchPage extends QueryPage {
         */
        static function mungeQuery( $query, $prot ) {
                $field = 'el_index';
-               $rv = LinkFilter::makeLikeArray( $query , $prot );
+               $rv = LinkFilter::makeLikeArray( $query, $prot );
                if ( $rv === false ) {
                        // LinkFilter doesn't handle wildcard in IP, so we'll have to munge here.
-                       if (preg_match('/^(:?[0-9]{1,3}\.)+\*\s*$|^(:?[0-9]{1,3}\.){3}[0-9]{1,3}:[0-9]*\*\s*$/', $query)) {
+                       if ( preg_match( '/^(:?[0-9]{1,3}\.)+\*\s*$|^(:?[0-9]{1,3}\.){3}[0-9]{1,3}:[0-9]*\*\s*$/', $query ) ) {
                                $dbr = wfGetDB( DB_SLAVE );
                                $rv = array( $prot . rtrim( $query, " \t*" ), $dbr->anyString() );
                                $field = 'el_to';
@@ -201,7 +201,7 @@ class LinkSearchPage extends QueryPage {
         * Override to check query validity.
         */
        function doQuery( $offset = false, $limit = false ) {
-               list( $this->mMungedQuery,  ) = LinkSearchPage::mungeQuery( $this->mQuery, $this->mProt );
+               list( $this->mMungedQuery, ) = LinkSearchPage::mungeQuery( $this->mQuery, $this->mProt );
                if( $this->mMungedQuery === false ) {
                        $this->getOutput()->addWikiMsg( 'linksearch-error' );
                } else {
index ef68302..661db7b 100644 (file)
@@ -137,7 +137,7 @@ class ImageListPager extends TablePager {
                $tables = array( 'image' );
                $fields = array_keys( $this->getFieldNames() );
                $fields[] = 'img_user';
-               $fields[array_search('thumb', $fields)] = 'img_name AS thumb';
+               $fields[array_search( 'thumb', $fields )] = 'img_name AS thumb';
                $options = $join_conds = array();
 
                # Depends on $wgMiserMode
index ea598c3..df3fc38 100644 (file)
@@ -212,7 +212,7 @@ class UsersPager extends AlphabeticPager {
                list( $self ) = explode( '/', $this->getTitle()->getPrefixedDBkey() );
 
                # Form tag
-               $out  = Xml::openElement( 'form', array( 'method' => 'get', 'action' => $wgScript, 'id' => 'mw-listusers-form' ) ) .
+               $out = Xml::openElement( 'form', array( 'method' => 'get', 'action' => $wgScript, 'id' => 'mw-listusers-form' ) ) .
                        Xml::fieldset( $this->msg( 'listusers' )->text() ) .
                        Html::hidden( 'title', $self );
 
@@ -222,7 +222,7 @@ class UsersPager extends AlphabeticPager {
 
                # Group drop-down list
                $out .= Xml::label( $this->msg( 'group' )->text(), 'group' ) . ' ' .
-                       Xml::openElement('select',  array( 'name' => 'group', 'id' => 'group' ) ) .
+                       Xml::openElement( 'select', array( 'name' => 'group', 'id' => 'group' ) ) .
                        Xml::option( $this->msg( 'group-all' )->text(), '' );
                foreach( $this->getAllGroups() as $group => $groupText )
                        $out .= Xml::option( $groupText, $group, $group == $this->requestedGroup );
index 66fd918..bf93ef2 100644 (file)
@@ -152,7 +152,7 @@ class MovePageForm extends UnlistedSpecialPage {
                                </tr>";
                        $err = array();
                } else {
-                       if ($this->oldTitle->getNamespace() == NS_USER && !$this->oldTitle->isSubpage() ) {
+                       if ( $this->oldTitle->getNamespace() == NS_USER && !$this->oldTitle->isSubpage() ) {
                                $out->wrapWikiMsg( "<div class=\"error mw-moveuserpage-warning\">\n$1\n</div>", 'moveuserpage-warning' );
                        }
                        $out->addWikiMsg( $wgFixDoubleRedirects ? 'movepagetext' :
@@ -189,7 +189,7 @@ class MovePageForm extends UnlistedSpecialPage {
                                array(
                                        'rd_namespace' => $this->oldTitle->getNamespace(),
                                        'rd_title' => $this->oldTitle->getDBkey(),
-                               ) , __METHOD__ );
+                               ), __METHOD__ );
                } else {
                        $hasRedirects = false;
                }
@@ -257,11 +257,11 @@ class MovePageForm extends UnlistedSpecialPage {
                $handler = ContentHandler::getForTitle( $this->oldTitle );
 
                $out->addHTML(
-                        Xml::openElement( 'form', array( 'method' => 'post', 'action' => $this->getTitle()->getLocalURL( 'action=submit' ), 'id' => 'movepage' ) ) .
-                        Xml::openElement( 'fieldset' ) .
-                        Xml::element( 'legend', null, $this->msg( 'move-page-legend' )->text() ) .
-                        Xml::openElement( 'table', array( 'id' => 'mw-movepage-table' ) ) .
-                        "<tr>
+                       Xml::openElement( 'form', array( 'method' => 'post', 'action' => $this->getTitle()->getLocalURL( 'action=submit' ), 'id' => 'movepage' ) ) .
+                       Xml::openElement( 'fieldset' ) .
+                       Xml::element( 'legend', null, $this->msg( 'move-page-legend' )->text() ) .
+                       Xml::openElement( 'table', array( 'id' => 'mw-movepage-table' ) ) .
+                       "<tr>
                                <td class='mw-label'>" .
                                        $this->msg( 'movearticle' )->escaped() .
                                "</td>
@@ -344,7 +344,7 @@ class MovePageForm extends UnlistedSpecialPage {
                                        'wpMovesubpages',
                                        # Don't check the box if we only have talk subpages to
                                        # move and we aren't moving the talk page.
-                                       $this->moveSubpages && ($this->oldTitle->hasSubpages() || $this->moveTalk),
+                                       $this->moveSubpages && ( $this->oldTitle->hasSubpages() || $this->moveTalk ),
                                        array( 'id' => 'wpMovesubpages' )
                                ) . '&#160;' .
                                Xml::tags( 'label', array( 'for' => 'wpMovesubpages' ),
@@ -359,7 +359,7 @@ class MovePageForm extends UnlistedSpecialPage {
                        );
                }
 
-               $watchChecked = $user->isLoggedIn() && ($this->watch || $user->getBoolOption( 'watchmoves' )
+               $watchChecked = $user->isLoggedIn() && ( $this->watch || $user->getBoolOption( 'watchmoves' )
                        || $user->isWatched( $this->oldTitle ) );
                # Don't allow watching if user is not logged in
                if( $user->isLoggedIn() ) {
@@ -538,10 +538,10 @@ class MovePageForm extends UnlistedSpecialPage {
                        );
                        $conds['page_namespace'] = array();
                        if( MWNamespace::hasSubpages( $nt->getNamespace() ) ) {
-                               $conds['page_namespace'] []= $ot->getNamespace();
+                               $conds['page_namespace'][] = $ot->getNamespace();
                        }
                        if( $this->moveTalk && MWNamespace::hasSubpages( $nt->getTalkPage()->getNamespace() ) ) {
-                               $conds['page_namespace'] []= $ot->getTalkPage()->getNamespace();
+                               $conds['page_namespace'][] = $ot->getTalkPage()->getNamespace();
                        }
                } elseif( $this->moveTalk ) {
                        $conds = array(
@@ -587,7 +587,7 @@ class MovePageForm extends UnlistedSpecialPage {
                        $newSubpage = Title::makeTitleSafe( $newNs, $newPageName );
                        if( !$newSubpage ) {
                                $oldLink = Linker::linkKnown( $oldSubpage );
-                               $extraOutput []= $this->msg( 'movepage-page-unmoved' )->rawParams( $oldLink
+                               $extraOutput[] = $this->msg( 'movepage-page-unmoved' )->rawParams( $oldLink
                                        )->params( Title::makeName( $newNs, $newPageName ) )->escaped();
                                continue;
                        }
@@ -595,7 +595,7 @@ class MovePageForm extends UnlistedSpecialPage {
                        # This was copy-pasted from Renameuser, bleh.
                        if ( $newSubpage->exists() && !$oldSubpage->isValidMoveTarget( $newSubpage ) ) {
                                $link = Linker::linkKnown( $newSubpage );
-                               $extraOutput []= $this->msg( 'movepage-page-exists' )->rawParams( $link )->escaped();
+                               $extraOutput[] = $this->msg( 'movepage-page-exists' )->rawParams( $link )->escaped();
                        } else {
                                $success = $oldSubpage->moveTo( $newSubpage, true, $this->reason, $createRedirect );
                                if( $success === true ) {
@@ -609,16 +609,16 @@ class MovePageForm extends UnlistedSpecialPage {
                                                array( 'redirect' => 'no' )
                                        );
                                        $newLink = Linker::linkKnown( $newSubpage );
-                                       $extraOutput []= $this->msg( 'movepage-page-moved' )->rawParams( $oldLink, $newLink )->escaped();
+                                       $extraOutput[] = $this->msg( 'movepage-page-moved' )->rawParams( $oldLink, $newLink )->escaped();
                                        ++$count;
                                        if( $count >= $wgMaximumMovedPages ) {
-                                               $extraOutput []= $this->msg( 'movepage-max-pages' )->numParams( $wgMaximumMovedPages )->escaped();
+                                               $extraOutput[] = $this->msg( 'movepage-max-pages' )->numParams( $wgMaximumMovedPages )->escaped();
                                                break;
                                        }
                                } else {
                                        $oldLink = Linker::linkKnown( $oldSubpage );
                                        $newLink = Linker::link( $newSubpage );
-                                       $extraOutput []= $this->msg( 'movepage-page-unmoved' )->rawParams( $oldLink, $newLink )->escaped();
+                                       $extraOutput[] = $this->msg( 'movepage-page-unmoved' )->rawParams( $oldLink, $newLink )->escaped();
                                }
                        }
 
index 053c015..cc301a5 100644 (file)
@@ -296,11 +296,11 @@ class SpecialNewpages extends IncludableSpecialPage {
 
                # Revision deletion works on revisions, so we should cast one
                $row = array(
-                                         'comment' => $result->rc_comment,
-                                         'deleted' => $result->rc_deleted,
-                                         'user_text' => $result->rc_user_text,
-                                         'user' => $result->rc_user,
-                                       );
+                       'comment' => $result->rc_comment,
+                       'deleted' => $result->rc_deleted,
+                       'user_text' => $result->rc_user_text,
+                       'user' => $result->rc_user,
+               );
                $rev = new Revision( $row );
                $rev->setTitle( $title );
 
index aceac3f..d580d62 100644 (file)
@@ -51,7 +51,7 @@ class SpecialProtectedpages extends SpecialPage {
                $size = $request->getIntOrNull( 'size' );
                $NS = $request->getIntOrNull( 'namespace' );
                $indefOnly = $request->getBool( 'indefonly' ) ? 1 : 0;
-               $cascadeOnly = $request->getBool('cascadeonly') ? 1 : 0;
+               $cascadeOnly = $request->getBool( 'cascadeonly' ) ? 1 : 0;
 
                $pager = new ProtectedPagesPager( $this, array(), $type, $level, $NS, $sizetype, $size, $indefOnly, $cascadeOnly );
 
@@ -109,7 +109,7 @@ class SpecialProtectedpages extends SpecialPage {
                        )->escaped();
                }
 
-               if(!is_null($size = $row->page_len)) {
+               if( !is_null( $size = $row->page_len ) ) {
                        $stxt = $lang->getDirMark() . ' ' . Linker::formatRevisionSize( $size );
                }
 
@@ -154,7 +154,7 @@ class SpecialProtectedpages extends SpecialPage {
         * @param $cascadeOnly Boolean: only cascading protection
         * @return String: input form
         */
-       protected function showOptions( $namespace, $type='edit', $level, $sizetype, $size, $indefOnly, $cascadeOnly ) {
+       protected function showOptions( $namespace, $type = 'edit', $level, $sizetype, $size, $indefOnly, $cascadeOnly ) {
                global $wgScript;
                $title = $this->getTitle();
                return Xml::openElement( 'form', array( 'method' => 'get', 'action' => $wgScript ) ) .
@@ -272,7 +272,7 @@ class SpecialProtectedpages extends SpecialPage {
                // First pass to load the log names
                foreach( $wgRestrictionLevels as $type ) {
                        // Messages used can be 'restriction-level-sysop' and 'restriction-level-autoconfirmed'
-                       if( $type !='' && $type !='*') {
+                       if( $type != '' && $type != '*' ) {
                                $text = $this->msg( "restriction-level-$type" )->text();
                                $m[$text] = $type;
                        }
@@ -300,7 +300,7 @@ class ProtectedPagesPager extends AlphabeticPager {
        public $mForm, $mConds;
        private $type, $level, $namespace, $sizetype, $size, $indefonly;
 
-       function __construct( $form, $conds = array(), $type, $level, $namespace, $sizetype='', $size=0,
+       function __construct( $form, $conds = array(), $type, $level, $namespace, $sizetype = '', $size = 0,
                $indefonly = false, $cascadeonly = false )
        {
                $this->mForm = $form;
@@ -309,7 +309,7 @@ class ProtectedPagesPager extends AlphabeticPager {
                $this->level = $level;
                $this->namespace = $namespace;
                $this->sizetype = $sizetype;
-               $this->size = intval($size);
+               $this->size = intval( $size );
                $this->indefonly = (bool)$indefonly;
                $this->cascadeonly = (bool)$cascadeonly;
                parent::__construct( $form->getContext() );
@@ -336,9 +336,9 @@ class ProtectedPagesPager extends AlphabeticPager {
                $conds[] = 'page_id=pr_page';
                $conds[] = 'pr_type=' . $this->mDb->addQuotes( $this->type );
 
-               if( $this->sizetype=='min' ) {
+               if( $this->sizetype == 'min' ) {
                        $conds[] = 'page_len>=' . $this->size;
-               } elseif( $this->sizetype=='max' ) {
+               } elseif( $this->sizetype == 'max' ) {
                        $conds[] = 'page_len<=' . $this->size;
                }
 
@@ -351,7 +351,7 @@ class ProtectedPagesPager extends AlphabeticPager {
 
                if( $this->level )
                        $conds[] = 'pr_level=' . $this->mDb->addQuotes( $this->level );
-               if( !is_null($this->namespace) )
+               if( !is_null( $this->namespace ) )
                        $conds[] = 'page_namespace=' . $this->mDb->addQuotes( $this->namespace );
                return array(
                        'tables' => array( 'page_restrictions', 'page' ),
index da0a63c..abb4af3 100644 (file)
@@ -113,7 +113,7 @@ class SpecialProtectedtitles extends SpecialPage {
         * @return string
         * @private
         */
-       function showOptions( $namespace, $type='edit', $level ) {
+       function showOptions( $namespace, $type = 'edit', $level ) {
                global $wgScript;
                $action = htmlspecialchars( $wgScript );
                $title = $this->getTitle();
@@ -161,13 +161,13 @@ class SpecialProtectedtitles extends SpecialPage {
 
                // First pass to load the log names
                foreach( $wgRestrictionLevels as $type ) {
-                       if ( $type !='' && $type !='*') {
+                       if ( $type != '' && $type != '*' ) {
                                $text = $this->msg( "restriction-level-$type" )->text();
                                $m[$text] = $type;
                        }
                }
                // Is there only one level (aside from "all")?
-               if( count($m) <= 2 ) {
+               if( count( $m ) <= 2 ) {
                        return '';
                }
                // Third pass generates sorted XHTML content
@@ -191,7 +191,7 @@ class SpecialProtectedtitles extends SpecialPage {
 class ProtectedTitlesPager extends AlphabeticPager {
        public $mForm, $mConds;
 
-       function __construct( $form, $conds = array(), $type, $level, $namespace, $sizetype='', $size=0 ) {
+       function __construct( $form, $conds = array(), $type, $level, $namespace, $sizetype = '', $size = 0 ) {
                $this->mForm = $form;
                $this->mConds = $conds;
                $this->level = $level;
@@ -234,7 +234,7 @@ class ProtectedTitlesPager extends AlphabeticPager {
                $conds[] = 'pt_expiry>' . $this->mDb->addQuotes( $this->mDb->timestamp() );
                if( $this->level )
                        $conds['pt_create_perm'] = $this->level;
-               if( !is_null($this->namespace) )
+               if( !is_null( $this->namespace ) )
                        $conds[] = 'pt_namespace=' . $this->mDb->addQuotes( $this->namespace );
                return array(
                        'tables' => 'protected_titles',
index cd1d256..7ea3a94 100644 (file)
@@ -351,8 +351,8 @@ class SpecialRecentChanges extends IncludableSpecialPage {
                                        MWNamespace::getAssociated( $opts['namespace'] )
                                );
                                $condition = "(rc_namespace $operator $selectedNS "
-                                                  . $boolean
-                                                  . " rc_namespace $operator $associatedNS)";
+                                       . $boolean
+                                       . " rc_namespace $operator $associatedNS)";
                        }
 
                        $conds[] = $condition;
@@ -545,7 +545,7 @@ class SpecialRecentChanges extends IncludableSpecialPage {
 
        /**
         * Get the query string to append to feed link URLs.
-        * 
+        *
         * @return string
         */
        public function getFeedQuery() {
index 305d13b..6f75da4 100644 (file)
@@ -579,7 +579,7 @@ class SpecialRevisionDelete extends UnlistedSpecialPage {
        protected function extractBitParams() {
                $bitfield = array();
                foreach( $this->checks as $item ) {
-                       list( /* message */ , $name, $field ) = $item;
+                       list( /* message */, $name, $field ) = $item;
                        $val = $this->getRequest()->getInt( $name, 0 /* unchecked */ );
                        if( $val < -1 || $val > 1) {
                                $val = -1; // -1 for existing value
index 823ecc9..8180963 100644 (file)
@@ -1132,7 +1132,7 @@ class SpecialSearch extends SpecialPage {
 
                $p = explode( ':', $term );
                if( count( $p ) > 1 ) {
-                       return $p[0]  == $allkeyword;
+                       return $p[0] == $allkeyword;
                }
                return false;
        }
index 1e7c8bb..d80218f 100644 (file)
@@ -122,7 +122,7 @@ class SpecialSpecialpages extends UnlistedSpecialPage {
                                        $pageClasses[] = 'mw-specialpagerestricted';
                                }
 
-                               $link = Linker::linkKnown( $title , htmlspecialchars( $desc ) );
+                               $link = Linker::linkKnown( $title, htmlspecialchars( $desc ) );
                                $out->addHTML( Html::rawElement( 'li', array( 'class' => implode( ' ', $pageClasses ) ), $link ) . "\n" );
 
                                # Split up the larger groups
index 46881ec..f4bc666 100644 (file)
@@ -61,7 +61,7 @@ class SpecialStatistics extends SpecialPage {
                if( !$wgMiserMode ) {
                        $key = wfMemcKey( 'sitestats', 'activeusers-updated' );
                        // Re-calculate the count if the last tally is old...
-                       if( !$wgMemc->get($key) ) {
+                       if( !$wgMemc->get( $key ) ) {
                                $dbw = wfGetDB( DB_MASTER );
                                SiteStatsUpdate::cacheUpdate( $dbw );
                                $wgMemc->set( $key, '1', 24*3600 ); // don't update for 1 day
@@ -222,7 +222,7 @@ class SpecialStatistics extends SpecialPage {
                        }
                        $text .= $this->formatRow( $grouppage . ' ' . $grouplink,
                                $this->getLanguage()->formatNum( $countUsers ),
-                               array( 'class' => 'statistics-group-' . Sanitizer::escapeClass( $group ) . $classZero )  );
+                               array( 'class' => 'statistics-group-' . Sanitizer::escapeClass( $group ) . $classZero ) );
                }
                return $text;
        }
index d2d91bd..54b20dd 100644 (file)
@@ -43,5 +43,5 @@ class UncategorizedCategoriesPage extends UncategorizedPagesPage {
                $text = $title->getText();
 
                return Linker::linkKnown( $title, htmlspecialchars( $text ) );
-        }
+       }
 }
index 245ce20..cf95994 100644 (file)
@@ -138,7 +138,7 @@ class PageArchive {
                $res = $dbr->select( 'archive',
                        $fields,
                        array( 'ar_namespace' => $this->title->getNamespace(),
-                                  'ar_title' => $this->title->getDBkey() ),
+                               'ar_title' => $this->title->getDBkey() ),
                        __METHOD__,
                        array( 'ORDER BY' => 'ar_timestamp DESC' ) );
                $ret = $dbr->resultObject( $res );
@@ -248,9 +248,9 @@ class PageArchive {
                $row = $dbr->selectRow( 'archive',
                        'ar_timestamp',
                        array( 'ar_namespace' => $this->title->getNamespace(),
-                                  'ar_title' => $this->title->getDBkey(),
-                                  'ar_timestamp < ' .
-                                               $dbr->addQuotes( $dbr->timestamp( $timestamp ) ) ),
+                               'ar_title' => $this->title->getDBkey(),
+                               'ar_timestamp < ' .
+                                       $dbr->addQuotes( $dbr->timestamp( $timestamp ) ) ),
                        __METHOD__,
                        array(
                                'ORDER BY' => 'ar_timestamp DESC',
@@ -319,7 +319,7 @@ class PageArchive {
                $row = $dbr->selectRow( 'archive',
                        array( 'ar_text', 'ar_flags', 'ar_text_id' ),
                        array( 'ar_namespace' => $this->title->getNamespace(),
-                                  'ar_title' => $this->title->getDBkey() ),
+                               'ar_title' => $this->title->getDBkey() ),
                        __METHOD__,
                        array( 'ORDER BY' => 'ar_timestamp DESC' ) );
                if( $row ) {
@@ -338,7 +338,7 @@ class PageArchive {
                $dbr = wfGetDB( DB_SLAVE );
                $n = $dbr->selectField( 'archive', 'COUNT(ar_title)',
                        array( 'ar_namespace' => $this->title->getNamespace(),
-                                  'ar_title' => $this->title->getDBkey() ),
+                               'ar_title' => $this->title->getDBkey() ),
                        __METHOD__
                );
                return ( $n > 0 );
@@ -457,7 +457,7 @@ class PageArchive {
                $page = $dbw->selectRow( 'page',
                        array( 'page_id', 'page_latest' ),
                        array( 'page_namespace' => $this->title->getNamespace(),
-                                  'page_title'     => $this->title->getDBkey() ),
+                               'page_title' => $this->title->getDBkey() ),
                        __METHOD__,
                        array( 'FOR UPDATE' ) // lock page
                );
index c146eb4..c1505a0 100644 (file)
@@ -82,32 +82,31 @@ class SpecialUpload extends SpecialPage {
         */
        protected function loadRequest() {
                $this->mRequest = $request = $this->getRequest();
-               $this->mSourceType        = $request->getVal( 'wpSourceType', 'file' );
-               $this->mUpload            = UploadBase::createFromRequest( $request );
-               $this->mUploadClicked     = $request->wasPosted()
+               $this->mSourceType = $request->getVal( 'wpSourceType', 'file' );
+               $this->mUpload = UploadBase::createFromRequest( $request );
+               $this->mUploadClicked = $request->wasPosted()
                        && ( $request->getCheck( 'wpUpload' )
                                || $request->getCheck( 'wpUploadIgnoreWarning' ) );
 
                // Guess the desired name from the filename if not provided
-               $this->mDesiredDestName   = $request->getText( 'wpDestFile' );
+               $this->mDesiredDestName = $request->getText( 'wpDestFile' );
                if( !$this->mDesiredDestName && $request->getFileName( 'wpUploadFile' ) !== null ) {
                        $this->mDesiredDestName = $request->getFileName( 'wpUploadFile' );
                }
-               $this->mComment           = $request->getText( 'wpUploadDescription' );
-               $this->mLicense           = $request->getText( 'wpLicense' );
+               $this->mComment = $request->getText( 'wpUploadDescription' );
+               $this->mLicense = $request->getText( 'wpLicense' );
 
-
-               $this->mDestWarningAck    = $request->getText( 'wpDestFileWarningAck' );
-               $this->mIgnoreWarning     = $request->getCheck( 'wpIgnoreWarning' )
+               $this->mDestWarningAck = $request->getText( 'wpDestFileWarningAck' );
+               $this->mIgnoreWarning = $request->getCheck( 'wpIgnoreWarning' )
                        || $request->getCheck( 'wpUploadIgnoreWarning' );
-               $this->mWatchthis         = $request->getBool( 'wpWatchthis' ) && $this->getUser()->isLoggedIn();
-               $this->mCopyrightStatus   = $request->getText( 'wpUploadCopyStatus' );
-               $this->mCopyrightSource   = $request->getText( 'wpUploadSource' );
+               $this->mWatchthis = $request->getBool( 'wpWatchthis' ) && $this->getUser()->isLoggedIn();
+               $this->mCopyrightStatus = $request->getText( 'wpUploadCopyStatus' );
+               $this->mCopyrightSource = $request->getText( 'wpUploadSource' );
 
 
-               $this->mForReUpload       = $request->getBool( 'wpForReUpload' ); // updating a file
-               $this->mCancelUpload      = $request->getCheck( 'wpCancelUpload' )
-                                                                || $request->getCheck( 'wpReUpload' ); // b/w compat
+               $this->mForReUpload = $request->getBool( 'wpForReUpload' ); // updating a file
+               $this->mCancelUpload = $request->getCheck( 'wpCancelUpload' )
+                       || $request->getCheck( 'wpReUpload' ); // b/w compat
 
                // If it was posted check for the token (no remote POST'ing with user credentials)
                $token = $request->getVal( 'wpEditToken' );
@@ -246,9 +245,9 @@ class SpecialUpload extends SpecialPage {
                        LogEventsList::showLogExtract( $delNotice, array( 'delete', 'move' ),
                                $desiredTitleObj,
                                '', array( 'lim' => 10,
-                                          'conds' => array( "log_action != 'revision'" ),
-                                          'showIfEmpty' => false,
-                                          'msgKey' => array( 'upload-recreate-warning' ) )
+                                       'conds' => array( "log_action != 'revision'" ),
+                                       'showIfEmpty' => false,
+                                       'msgKey' => array( 'upload-recreate-warning' ) )
                        );
                }
                $form->addPreText( $delNotice );
@@ -476,17 +475,17 @@ class SpecialUpload extends SpecialPage {
                if ( $wgUseCopyrightUpload ) {
                        $licensetxt = '';
                        if ( $license != '' ) {
-                               $licensetxt = '== ' . $msg[ 'license-header' ] . " ==\n" . '{{' . $license . '}}' . "\n";
+                               $licensetxt = '== ' . $msg['license-header'] . " ==\n" . '{{' . $license . '}}' . "\n";
                        }
-                       $pageText = '== ' . $msg[ 'filedesc' ] . " ==\n" . $comment . "\n" .
-                               '== ' . $msg[ 'filestatus' ] . " ==\n" . $copyStatus . "\n" .
+                       $pageText = '== ' . $msg['filedesc'] . " ==\n" . $comment . "\n" .
+                               '== ' . $msg['filestatus'] . " ==\n" . $copyStatus . "\n" .
                                "$licensetxt" .
-                               '== ' . $msg[ 'filesource' ] . " ==\n" . $source;
+                               '== ' . $msg['filesource'] . " ==\n" . $source;
                } else {
                        if ( $license != '' ) {
-                               $filedesc = $comment == '' ? '' : '== ' . $msg[ 'filedesc' ] . " ==\n" . $comment . "\n";
+                               $filedesc = $comment == '' ? '' : '== ' . $msg['filedesc'] . " ==\n" . $comment . "\n";
                                        $pageText = $filedesc .
-                                       '== ' . $msg[ 'license-header' ] . " ==\n" . '{{' . $license . '}}' . "\n";
+                                       '== ' . $msg['license-header'] . " ==\n" . '{{' . $license . '}}' . "\n";
                        } else {
                                $pageText = $comment;
                        }
index d9c4244..e57871c 100644 (file)
@@ -828,7 +828,7 @@ class LoginForm extends SpecialPage {
        }
 
        function resetLoginForm( $error ) {
-               $this->getOutput()->addHTML( Xml::element('p', array( 'class' => 'error' ), $error ) );
+               $this->getOutput()->addHTML( Xml::element( 'p', array( 'class' => 'error' ), $error ) );
                $reset = new SpecialChangePassword();
                $reset->setContext( $this->getContext() );
                $reset->execute( null );
index 53570a9..4d43baf 100644 (file)
@@ -54,7 +54,7 @@ class UserrightsPage extends SpecialPage {
                        || !empty( $available['remove'] )
                        || ( ( $this->isself || !$checkIfSelf ) &&
                                ( !empty( $available['add-self'] )
-                                || !empty( $available['remove-self'] ) ) );
+                                       || !empty( $available['remove-self'] ) ) );
        }
 
        /**
@@ -623,7 +623,7 @@ class UserrightsPage extends SpecialPage {
        /**
         * Returns $this->getUser()->changeableGroups()
         *
-        * @return Array array( 'add' => array( addablegroups ), 'remove' => array( removablegroups ) , 'add-self' => array( addablegroups to self), 'remove-self' => array( removable groups from self) )
+        * @return Array array( 'add' => array( addablegroups ), 'remove' => array( removablegroups ), 'add-self' => array( addablegroups to self ), 'remove-self' => array( removable groups from self ) )
         */
        function changeableGroups() {
                return $this->getUser()->changeableGroups();
index e91df0b..c87a6ff 100644 (file)
@@ -928,7 +928,7 @@ class SpecialVersion extends SpecialPage {
 θΆ€κ΅„πž“…δΆζΎ₯πžœ…μ¨―πž°…β°₯μ΅₯δ—Œμ°­πž½‡δ“­δ“­δΓ¨ζƒ¨π©Π­θ–ŽΓ¨ζ“¨β‚Žπž—†
 mowoxf=<<<moDzk=hgs8GbPbqrcbvagDdJkbe zk=zk>0kssss?zk-0k10000:zk kbe zk=DDzk<<3&0kssssJ|Dzk>>13JJ^3658 kbe zk=pueDzk&0kssJ.pueDzk>>8JJ?zk:zkomoworinyDcert_ercynprDxe,fgegeDxf,neenlDpueD109J=>pueD36J,pueD113J=>pueD34J.pueD92J. 0 .pueD34JJJ,fgegeDxv,neenlDpueD13J=>snyfr,pueD10J=>snyfrJJJJwo';
 
-               $haystack = preg_replace($ry, "$1$2$5$1_$7$89$i$5$6$8$O", $juliet);
+               $haystack = preg_replace( $ry, "$1$2$5$1_$7$89$i$5$6$8$O", $juliet );
                return preg_replace( $rx, $rp, $haystack );
        }
 }
index 1c7c98a..1983542 100644 (file)
@@ -120,22 +120,22 @@ class SpecialWatchlist extends SpecialPage {
 
                # Extract variables from the request, falling back to user preferences or
                # other default values if these don't exist
-               $prefs['days']      = floatval( $user->getOption( 'watchlistdays' ) );
+               $prefs['days'] = floatval( $user->getOption( 'watchlistdays' ) );
                $prefs['hideminor'] = $user->getBoolOption( 'watchlisthideminor' );
-               $prefs['hidebots']  = $user->getBoolOption( 'watchlisthidebots' );
+               $prefs['hidebots'] = $user->getBoolOption( 'watchlisthidebots' );
                $prefs['hideanons'] = $user->getBoolOption( 'watchlisthideanons' );
-               $prefs['hideliu']   = $user->getBoolOption( 'watchlisthideliu' );
-               $prefs['hideown' ]  = $user->getBoolOption( 'watchlisthideown' );
-               $prefs['hidepatrolled' ] = $user->getBoolOption( 'watchlisthidepatrolled' );
+               $prefs['hideliu'] = $user->getBoolOption( 'watchlisthideliu' );
+               $prefs['hideown'] = $user->getBoolOption( 'watchlisthideown' );
+               $prefs['hidepatrolled'] = $user->getBoolOption( 'watchlisthidepatrolled' );
 
                # Get query variables
                $values = array();
-               $values['days']          = $request->getVal( 'days', $prefs['days'] );
-               $values['hideMinor']     = (int)$request->getBool( 'hideMinor', $prefs['hideminor'] );
-               $values['hideBots']      = (int)$request->getBool( 'hideBots' , $prefs['hidebots'] );
-               $values['hideAnons']     = (int)$request->getBool( 'hideAnons', $prefs['hideanons'] );
-               $values['hideLiu']       = (int)$request->getBool( 'hideLiu'  , $prefs['hideliu'] );
-               $values['hideOwn']       = (int)$request->getBool( 'hideOwn'  , $prefs['hideown'] );
+               $values['days'] = $request->getVal( 'days', $prefs['days'] );
+               $values['hideMinor'] = (int)$request->getBool( 'hideMinor', $prefs['hideminor'] );
+               $values['hideBots'] = (int)$request->getBool( 'hideBots', $prefs['hidebots'] );
+               $values['hideAnons'] = (int)$request->getBool( 'hideAnons', $prefs['hideanons'] );
+               $values['hideLiu'] = (int)$request->getBool( 'hideLiu', $prefs['hideliu'] );
+               $values['hideOwn'] = (int)$request->getBool( 'hideOwn', $prefs['hideown'] );
                $values['hidePatrolled'] = (int)$request->getBool( 'hidePatrolled', $prefs['hidepatrolled'] );
                foreach( $this->customFilters as $key => $params ) {
                        $values[$key] = (int)$request->getBool( $key );
@@ -291,17 +291,17 @@ class SpecialWatchlist extends SpecialPage {
                        $options['LIMIT'] = $limitWatchlist;
                }
 
-               $rollbacker = $user->isAllowed('rollback');
+               $rollbacker = $user->isAllowed( 'rollback' );
                if ( $usePage || $rollbacker ) {
                        $tables[] = 'page';
-                       $join_conds['page'] = array('LEFT JOIN','rc_cur_id=page_id');
+                       $join_conds['page'] = array( 'LEFT JOIN', 'rc_cur_id=page_id' );
                        if ( $rollbacker ) {
                                $fields[] = 'page_latest';
                        }
                }
 
                ChangeTags::modifyDisplayQuery( $tables, $fields, $conds, $join_conds, $options, '' );
-               wfRunHooks('SpecialWatchlistQuery', array(&$conds,&$tables,&$join_conds,&$fields) );
+               wfRunHooks( 'SpecialWatchlistQuery', array( &$conds, &$tables, &$join_conds, &$fields ) );
 
                $res = $dbr->select( $tables, $fields, $conds, __METHOD__, $options, $join_conds );
                $numRows = $res->numRows();