http://www.mediawiki.org/wiki/Special:Code/MediaWiki/62008

Revision: 62008
Author:   mah
Date:     2010-02-05 04:25:30 +0000 (Fri, 05 Feb 2010)

Log Message:
-----------
Random whitespace cleanup

Modified Paths:
--------------
    trunk/phase3/includes/MessageCache.php
    trunk/phase3/includes/Namespace.php
    trunk/phase3/includes/upload/UploadFromUrl.php

Modified: trunk/phase3/includes/MessageCache.php
===================================================================
--- trunk/phase3/includes/MessageCache.php      2010-02-05 04:08:19 UTC (rev 
62007)
+++ trunk/phase3/includes/MessageCache.php      2010-02-05 04:25:30 UTC (rev 
62008)
@@ -256,7 +256,7 @@
 
                        $this->lock($cacheKey);
 
-                       # Limit the concurrency of loadFromDB to a single 
process 
+                       # Limit the concurrency of loadFromDB to a single 
process
                        # This prevents the site from going down when the cache 
expires
                        $statusKey = wfMemcKey( 'messages', $code, 'status' );
                        $success = $this->mMemc->add( $statusKey, 'loading', 
MSG_LOAD_TIMEOUT );
@@ -562,7 +562,7 @@
                }
 
                # Fix whitespace
-               $message = strtr( $message, 
+               $message = strtr( $message,
                        array(
                                # Fix for trailing whitespace, removed by 
textarea
                                ' ' => ' ',
@@ -677,7 +677,7 @@
 
        function disable() { $this->mDisable = true; }
        function enable() { $this->mDisable = false; }
- 
+
        /** @deprecated */
        function disableTransform(){
                wfDeprecated( __METHOD__ );

Modified: trunk/phase3/includes/Namespace.php
===================================================================
--- trunk/phase3/includes/Namespace.php 2010-02-05 04:08:19 UTC (rev 62007)
+++ trunk/phase3/includes/Namespace.php 2010-02-05 04:25:30 UTC (rev 62008)
@@ -46,8 +46,8 @@
 class MWNamespace {
 
        /**
-        * These namespaces should always be first-letter capitalized, now and 
-        * forevermore. Historically, they could've probably been lowercased 
too, 
+        * These namespaces should always be first-letter capitalized, now and
+        * forevermore. Historically, they could've probably been lowercased 
too,
         * but some things are just too ingrained now. :)
         */
        private static $alwaysCapitalizedNamespaces = array( NS_SPECIAL, 
NS_USER, NS_MEDIAWIKI );
@@ -107,7 +107,7 @@
                        ? $index - 1
                        : $index;
        }
-       
+
        /**
         * Returns whether the specified namespace exists
         */
@@ -162,7 +162,7 @@
         * @return bool
         */
         public static function canTalk( $index ) {
-               return $index >= NS_MAIN;
+               return $index >= NS_MAIN;
         }
 
        /**
@@ -197,10 +197,10 @@
                global $wgNamespacesWithSubpages;
                return !empty( $wgNamespacesWithSubpages[$index] );
        }
-       
+
        /**
         * Is the namespace first-letter capitalized?
-        * 
+        *
         * @param $index int Index to check
         * @return bool
         */
@@ -208,10 +208,10 @@
                global $wgCapitalLinks, $wgCapitalLinkOverrides;
                // Turn NS_MEDIA into NS_FILE
                $index = $index === NS_MEDIA ? NS_FILE : $index;
-               
+
                // Make sure to get the subject of our namespace
                $index = self::getSubject( $index );
-               
+
                // Some namespaces are special and should always be upper case
                if ( in_array( $index, self::$alwaysCapitalizedNamespaces ) ) {
                        return true;

Modified: trunk/phase3/includes/upload/UploadFromUrl.php
===================================================================
--- trunk/phase3/includes/upload/UploadFromUrl.php      2010-02-05 04:08:19 UTC 
(rev 62007)
+++ trunk/phase3/includes/upload/UploadFromUrl.php      2010-02-05 04:25:30 UTC 
(rev 62008)
@@ -2,9 +2,9 @@
 /**
  * @file
  * @ingroup upload
- * 
+ *
  * Implements uploading from a HTTP resource.
- * 
+ *
  * @author Bryan Tong Minh
  * @author Michael Dale
  */
@@ -12,7 +12,7 @@
        protected $mTempDownloadPath;
 
        /**
-        * Checks if the user is allowed to use the upload-by-URL feature. If 
the 
+        * Checks if the user is allowed to use the upload-by-URL feature. If 
the
         * user is allowed, pass on permissions checking to the parent.
         */
        public static function isAllowed( $user ) {
@@ -29,8 +29,8 @@
                return $wgAllowCopyUploads && parent::isEnabled();
        }
 
-       /** 
-        * Entry point for API upload 
+       /**
+        * Entry point for API upload
         */
        public function initialize( $name, $url, $na, $nb = false ) {
                global $wgTmpDirectory;
@@ -51,7 +51,7 @@
                        $desiredDestName = $request->getText( 'wpUploadFileURL' 
);
                return $this->initialize(
                        $desiredDestName,
-                       $request->getVal( 'wpUploadFileURL' ),
+                       $request->getVal( 'wpUploadFileURL' ),
                        false
                );
        }
@@ -70,7 +70,7 @@
                // Only allow HTTP or FTP for now
                return (bool)preg_match( '!^(http://|ftp://)!', $url );
        }
-       
+
        /**
         * Do the real fetching stuff
         */
@@ -84,7 +84,7 @@
                }
                return Status::newGood();
        }
-       
+
        /**
         * Safe copy from URL
         * Returns true if there was an error, false otherwise
@@ -111,13 +111,13 @@
 
                fclose( $this->mCurlDestHandle );
                unset( $this->mCurlDestHandle );
-               
-               if( $error ) 
+
+               if( $error )
                        return "upload-curl-error$errornum";
 
                return true;
        }
-       
+
        /**
         * Callback function for CURL-based web transfer
         * Write data to file unless we've passed the length limit;
@@ -127,7 +127,7 @@
        function uploadCurlCallback( $ch, $data ) {
                global $wgMaxUploadSize;
                $length = strlen( $data );
-               $this->mFileSize += $length; 
+               $this->mFileSize += $length;
                if( $this->mFileSize > $wgMaxUploadSize ) {
                        return 0;
                }



_______________________________________________
MediaWiki-CVS mailing list
MediaWiki-CVS@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to