$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()
// 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() );
$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;
}
* Failures here must throw subclasses of ErrorPageError.
* @param User $user
* @throws UserBlockedError
- * @return bool True
*/
protected function checkExecutePermissions( User $user ) {
$this->checkPermissions();
if ( $this->requiresWrite() ) {
$this->checkReadOnly();
}
-
- return true;
}
/**