Merge "Add GENDER support to $3 in logentry-rights-rights"
[lhc/web/wiklou.git] / includes / specialpage / FormSpecialPage.php
index d22875b..c28c456 100644 (file)
@@ -95,7 +95,7 @@ abstract class FormSpecialPage extends SpecialPage {
                        $this->getContext(),
                        $this->getMessagePrefix()
                );
-               $form->setSubmitCallback( array( $this, 'onSubmit' ) );
+               $form->setSubmitCallback( [ $this, 'onSubmit' ] );
                if ( $this->getDisplayFormat() !== 'ooui' ) {
                        // No legend and wrapper by default in OOUI forms, but can be set manually
                        // from alterForm()
@@ -109,7 +109,7 @@ abstract class FormSpecialPage extends SpecialPage {
 
                // Retain query parameters (uselang etc)
                $params = array_diff_key(
-                       $this->getRequest()->getQueryValues(), array( 'title' => null ) );
+                       $this->getRequest()->getQueryValues(), [ 'title' => null ] );
                $form->addHiddenField( 'redirectparams', wfArrayToCgi( $params ) );
 
                $form->addPreText( $this->preText() );
@@ -117,7 +117,7 @@ abstract class FormSpecialPage extends SpecialPage {
                $this->alterForm( $form );
 
                // Give hooks a chance to alter the form, adding extra fields or text etc
-               Hooks::run( 'SpecialPageBeforeFormDisplay', array( $this->getName(), &$form ) );
+               Hooks::run( 'SpecialPageBeforeFormDisplay', [ $this->getName(), &$form ] );
 
                return $form;
        }