Merge "Fix separated login link so that create account and login are always next...
[lhc/web/wiklou.git] / includes / Block.php
index 51d22ee..6e8f9f3 100644 (file)
@@ -137,13 +137,13 @@ class Block {
                }
        }
 
-       /**\r
-        * Return the list of ipblocks fields that should be selected to create\r
-        * a new block.\r
-        * @return array\r
-        */\r
-       public static function selectFields() {\r
-               return array(\r
+       /**
+        * Return the list of ipblocks fields that should be selected to create
+        * a new block.
+        * @return array
+        */
+       public static function selectFields() {
+               return array(
                        'ipb_id',
                        'ipb_address',
                        'ipb_by',
@@ -158,8 +158,8 @@ class Block {
                        'ipb_deleted',
                        'ipb_block_email',
                        'ipb_allow_usertalk',
-                       'ipb_parent_block_id',\r
-               );\r
+                       'ipb_parent_block_id',
+               );
        }
 
        /**
@@ -613,7 +613,7 @@ class Block {
                $key = wfMemcKey( 'ipb', 'autoblock', 'whitelist' );
                $lines = $wgMemc->get( $key );
                if ( !$lines ) {
-                       $lines = explode( "\n", wfMsgForContentNoTrans( 'autoblock_whitelist' ) );
+                       $lines = explode( "\n", wfMessage( 'autoblock_whitelist' )->inContentLanguage()->plain() );
                        $wgMemc->set( $key, $lines, 3600 * 24 );
                }
 
@@ -687,7 +687,7 @@ class Block {
                wfDebug( "Autoblocking {$this->getTarget()}@" . $autoblockIP . "\n" );
                $autoblock->setTarget( $autoblockIP );
                $autoblock->setBlocker( $this->getBlocker() );
-               $autoblock->mReason = wfMsgForContent( 'autoblocker', $this->getTarget(), $this->mReason );
+               $autoblock->mReason = wfMessage( 'autoblocker', $this->getTarget(), $this->mReason )->inContentLanguage()->text();
                $timestamp = wfTimestampNow();
                $autoblock->mTimestamp = $timestamp;
                $autoblock->mAuto = 1;
@@ -1020,7 +1020,7 @@ class Block {
                        $keys = array( 'infiniteblock', 'expiringblock' );
 
                        foreach ( $keys as $key ) {
-                               $msg[$key] = wfMsgHtml( $key );
+                               $msg[$key] = wfMessage( $key )->escaped();
                        }
                }