X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fspecials%2FSpecialPasswordReset.php;h=a2dc2add28ea82050b085a63d807750d4ff8e873;hb=145f1c1bb4dfa6e173bdd5dcbabfedbe91722daf;hp=3061c85b12f36cad5c4172b64cdebeed07e04f4e;hpb=9f50256cc5b9dac53a8a2d11f43a409d4421506f;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/specials/SpecialPasswordReset.php b/includes/specials/SpecialPasswordReset.php index 3061c85b12..a2dc2add28 100644 --- a/includes/specials/SpecialPasswordReset.php +++ b/includes/specials/SpecialPasswordReset.php @@ -103,16 +103,13 @@ class SpecialPasswordReset extends FormSpecialPage { return $a; } + protected function getDisplayFormat() { + return 'vform'; + } + public function alterForm( HTMLForm $form ) { $resetRoutes = $this->getConfig()->get( 'PasswordResetRoutes' ); - $form->setDisplayFormat( 'vform' ); - // Turn the old-school line around the form off. - // XXX This wouldn't be necessary here if we could set the format of - // the HTMLForm to 'vform' at its creation, but there's no way to do so - // from a FormSpecialPage class. - $form->setWrapperLegend( false ); - $form->addHiddenFields( $this->getRequest()->getValues( 'returnto', 'returntoquery' ) ); $i = 0; @@ -195,7 +192,7 @@ class SpecialPasswordReset extends FormSpecialPage { // Check for hooks (captcha etc), and allow them to modify the users list $error = array(); - if ( !wfRunHooks( 'SpecialPasswordResetOnSubmit', array( &$users, $data, &$error ) ) ) { + if ( !Hooks::run( 'SpecialPasswordResetOnSubmit', array( &$users, $data, &$error ) ) ) { return array( $error ); } @@ -246,7 +243,7 @@ class SpecialPasswordReset extends FormSpecialPage { return array( 'badipaddress' ); } $caller = $this->getUser(); - wfRunHooks( 'User::mailPasswordInternal', array( &$caller, &$ip, &$firstUser ) ); + Hooks::run( 'User::mailPasswordInternal', array( &$caller, &$ip, &$firstUser ) ); $username = $caller->getName(); $msg = IP::isValid( $username ) ? 'passwordreset-emailtext-ip'