Merge "(bug 42787) Make import robust against corrupt content."
[lhc/web/wiklou.git] / includes / specials / SpecialUnblock.php
index 4ad31a0..853a805 100644 (file)
@@ -1,5 +1,7 @@
 <?php
 /**
+ * Implements Special:Unblock
+ *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
@@ -58,14 +60,14 @@ class SpecialUnblock extends SpecialPage {
                        switch( $this->type ){
                                case Block::TYPE_USER:
                                case Block::TYPE_IP:
-                                       $out->addWikiMsg( 'unblocked',  $this->target );
+                                       $out->addWikiMsg( 'unblocked', wfEscapeWikiText( $this->target ) );
                                        break;
                                case Block::TYPE_RANGE:
-                                       $out->addWikiMsg( 'unblocked-range', $this->target );
+                                       $out->addWikiMsg( 'unblocked-range', wfEscapeWikiText( $this->target ) );
                                        break;
                                case Block::TYPE_ID:
                                case Block::TYPE_AUTO:
-                                       $out->addWikiMsg( 'unblocked-id', $this->target );
+                                       $out->addWikiMsg( 'unblocked-id', wfEscapeWikiText( $this->target ) );
                                        break;
                        }
                }
@@ -147,6 +149,7 @@ class SpecialUnblock extends SpecialPage {
         *
         * @param $data Array
         * @param $context IContextSource
+        * @throws ErrorPageError
         * @return Array( Array(message key, parameters) ) on failure, True on success
         */
        public static function processUnblock( array $data, IContextSource $context ){