Added spaces before and removed spaces after 'array'
[lhc/web/wiklou.git] / includes / specials / SpecialProtectedpages.php
index eb89bec..979c3ee 100644 (file)
@@ -83,9 +83,16 @@ class SpecialProtectedpages extends SpecialPage {
                }
 
                $title = Title::makeTitleSafe( $row->page_namespace, $row->page_title );
+               if( !$title ) {
+                       wfProfileOut( __METHOD__ );
+                       return Html::rawElement( 'li', array(),
+                               Html::element( 'span', array( 'class' => 'mw-invalidtitle' ),
+                                       Linker::getInvalidTitleDescription( $this->getContext(), $row->page_namespace, $row->page_title ) ) ) . "\n";
+               }
+
                $link = Linker::link( $title );
 
-               $description_items = array ();
+               $description_items = array();
 
                $protType = $this->msg( 'restriction-level-' . $row->pr_level )->escaped();
 
@@ -190,8 +197,8 @@ class SpecialProtectedpages extends SpecialPage {
                                        'all' => '',
                                        'label' => $this->msg( 'namespace' )->text()
                                ), array(
-                                       'name'  => 'namespace',
-                                       'id'    => 'namespace',
+                                       'name' => 'namespace',
+                                       'id' => 'namespace',
                                        'class' => 'namespaceselector',
                                )
                        )
@@ -199,29 +206,30 @@ class SpecialProtectedpages extends SpecialPage {
        }
 
        /**
+        * @param bool $indefOnly
         * @return string Formatted HTML
         */
        protected function getExpiryCheck( $indefOnly ) {
-               return
-                       Xml::checkLabel( $this->msg( 'protectedpages-indef' )->text(), 'indefonly', 'indefonly', $indefOnly ) . "\n";
+               return Xml::checkLabel( $this->msg( 'protectedpages-indef' )->text(), 'indefonly', 'indefonly', $indefOnly ) . "\n";
        }
 
        /**
+        * @param bool $cascadeOnly
         * @return string Formatted HTML
         */
        protected function getCascadeCheck( $cascadeOnly ) {
-               return
-                       Xml::checkLabel( $this->msg( 'protectedpages-cascade' )->text(), 'cascadeonly', 'cascadeonly', $cascadeOnly ) . "\n";
+               return Xml::checkLabel( $this->msg( 'protectedpages-cascade' )->text(), 'cascadeonly', 'cascadeonly', $cascadeOnly ) . "\n";
        }
 
        /**
+        * @param string $sizetype "min" or "max"
+        * @param mixed $size
         * @return string Formatted HTML
         */
        protected function getSizeLimit( $sizetype, $size ) {
                $max = $sizetype === 'max';
 
-               return
-                       Xml::radioLabel( $this->msg( 'minimum-size' )->text(), 'sizetype', 'min', 'wpmin', !$max ) .
+               return Xml::radioLabel( $this->msg( 'minimum-size' )->text(), 'sizetype', 'min', 'wpmin', !$max ) .
                        ' ' .
                        Xml::radioLabel( $this->msg( 'maximum-size' )->text(), 'sizetype', 'max', 'wpmax', $max ) .
                        ' ' .