Merge "Fix phpcs errors and warnings in includes/exception"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Sun, 15 Mar 2015 02:45:32 +0000 (02:45 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Sun, 15 Mar 2015 02:45:32 +0000 (02:45 +0000)
includes/filerepo/FileRepoStatus.php
includes/filerepo/file/LocalFile.php
includes/json/FormatJson.php
includes/skins/BaseTemplate.php
includes/skins/Skin.php

index daf26ba..67080b6 100644 (file)
@@ -26,4 +26,5 @@
  * @ingroup FileRepo
  * @deprecated 1.25
  */
-class FileRepoStatus extends Status {}
+class FileRepoStatus extends Status {
+}
index e5ce220..be5ca7f 100644 (file)
@@ -1784,7 +1784,10 @@ class LocalFile extends File {
                // itself gets it from elsewhere. To avoid repeating the DB lookups in such a case, we
                // need to differentiate between null (uninitialized) and false (failed to load).
                if ( $this->descriptionTouched === null ) {
-                       $cond = array( 'page_namespace' => $this->title->getNamespace(), 'page_title' => $this->title->getDBkey() );
+                       $cond = array(
+                               'page_namespace' => $this->title->getNamespace(),
+                               'page_title' => $this->title->getDBkey()
+                       );
                        $touched = $this->repo->getSlaveDB()->selectField( 'page', 'page_touched', $cond, __METHOD__ );
                        $this->descriptionTouched = $touched ? wfTimestamp( TS_MW, $touched ) : false;
                }
index 74775b5..f27194a 100644 (file)
@@ -137,8 +137,9 @@ class FormatJson {
        }
 
        /**
-        * Decodes a JSON string. It is recommended to use FormatJson::parse(), which returns more comprehensive
-        * result in case of an error, and has more parsing options.
+        * Decodes a JSON string. It is recommended to use FormatJson::parse(),
+        * which returns more comprehensive result in case of an error, and has
+        * more parsing options.
         *
         * @param string $value The JSON string being decoded
         * @param bool $assoc When true, returned objects will be converted into associative arrays.
@@ -154,7 +155,8 @@ class FormatJson {
 
        /**
         * Decodes a JSON string.
-        * Unlike FormatJson::decode(), if $value represents null value, it will be properly decoded as valid.
+        * Unlike FormatJson::decode(), if $value represents null value, it will be
+        * properly decoded as valid.
         *
         * @param string $value The JSON string being decoded
         * @param int $options A bit field that allows FORCE_ASSOC, TRY_FIXING,
index eedd2a1..25df0f9 100644 (file)
@@ -634,7 +634,8 @@ abstract class BaseTemplate extends QuickTemplate {
         * debug stuff. This should be called right before outputting the closing
         * body and html tags.
         */
-       function printTrail() { ?>
+       function printTrail() {
+?>
 <?php echo MWDebug::getDebugHTML( $this->getSkin()->getContext() ); ?>
 <?php $this->html( 'bottomscripts' ); /* JS call to runBodyOnloadHook */ ?>
 <?php $this->html( 'reporttime' ) ?>
index 1549bbd..48bce67 100644 (file)
@@ -837,9 +837,15 @@ abstract class Skin extends ContextSource {
        function getPoweredBy() {
                global $wgResourceBasePath;
 
-               $url1 = htmlspecialchars( "$wgResourceBasePath/resources/assets/poweredby_mediawiki_88x31.png" );
-               $url1_5 = htmlspecialchars( "$wgResourceBasePath/resources/assets/poweredby_mediawiki_132x47.png" );
-               $url2 = htmlspecialchars( "$wgResourceBasePath/resources/assets/poweredby_mediawiki_176x62.png" );
+               $url1 = htmlspecialchars(
+                       "$wgResourceBasePath/resources/assets/poweredby_mediawiki_88x31.png"
+               );
+               $url1_5 = htmlspecialchars(
+                       "$wgResourceBasePath/resources/assets/poweredby_mediawiki_132x47.png"
+               );
+               $url2 = htmlspecialchars(
+                       "$wgResourceBasePath/resources/assets/poweredby_mediawiki_176x62.png"
+               );
                $text = '<a href="//www.mediawiki.org/"><img src="' . $url1
                        . '" srcset="' . $url1_5 . ' 1.5x, ' . $url2 . ' 2x" '
                        . 'height="31" width="88" alt="Powered by MediaWiki" /></a>';
@@ -1619,7 +1625,11 @@ abstract class Skin extends ContextSource {
 
                $result .= '<span class="mw-editsection-bracket">]</span></span>';
                // Deprecated, use SkinEditSectionLinks hook instead
-               Hooks::run( 'DoEditSectionLink', array( $this, $nt, $section, $tooltip, &$result, $lang ), '1.25' );
+               Hooks::run(
+                       'DoEditSectionLink',
+                       array( $this, $nt, $section, $tooltip, &$result, $lang ),
+                       '1.25'
+               );
                return $result;
        }