Merge "Combine SpecialPageBeforeFormDisplay set of hooks into one"

This commit is contained in:
jenkins-bot 2014-06-29 00:37:42 +00:00 committed by Gerrit Code Review
commit 040060e2b7
3 changed files with 8 additions and 1 deletions

View file

@ -197,6 +197,9 @@ changes to languages because of Bugzilla reports.
* Removed DatabaseMysqlBase::getLagFromProcesslist(). (deprecated since 1.19)
* Removed LoadBalancer::closeConnecton(). (deprecated since 1.18)
* Removed ApiBase::createContext(). (deprecated since 1.19)
* BREAKING CHANGE: The undocumented Special{$this->getName()}BeforeFormDisplay
set of hooks has been removed and replaced by a single new hook
SpecialPageBeforeFormDisplay.
==== Renamed classes ====
* CLDRPluralRuleConverter_Expression to CLDRPluralRuleConverterExpression

View file

@ -2354,6 +2354,10 @@ software.
$software: The array of software in format 'name' => 'version'. See
SpecialVersion::softwareInformation().
'SpecialPageBeforeFormDisplay': Before executing the HTMLForm object.
$name: name of the special page
&$form: HTMLForm object
'SpecialBlockModifyFormFields': Add more fields to Special:Block
$sp: SpecialPage object, for context
&$fields: Current HTMLForm fields

View file

@ -106,7 +106,7 @@ abstract class FormSpecialPage extends SpecialPage {
$this->alterForm( $form );
// Give hooks a chance to alter the form, adding extra fields or text etc
wfRunHooks( "Special{$this->getName()}BeforeFormDisplay", array( &$form ) );
wfRunHooks( 'SpecialPageBeforeFormDisplay', array( $this->getName(), &$form ) );
return $form;
}