X-Git-Url: http://aleph1.co.uk/gitweb/?a=blobdiff_plain;f=web%2Fcore%2Fmodules%2Fuser%2Fsrc%2FForm%2FUserPasswordForm.php;h=b805641989765230c9e228bc1f75f7eb5cf6b099;hb=0bf8d09d2542548982e81a441b1f16e75873a04f;hp=ea224fe439e9859bf6765530e953efebcb83ad44;hpb=a2bd1bf0c2c1f1a17d188f4dc0726a45494cefae;p=yaffs-website diff --git a/web/core/modules/user/src/Form/UserPasswordForm.php b/web/core/modules/user/src/Form/UserPasswordForm.php index ea224fe43..b80564198 100644 --- a/web/core/modules/user/src/Form/UserPasswordForm.php +++ b/web/core/modules/user/src/Form/UserPasswordForm.php @@ -11,6 +11,8 @@ use Symfony\Component\DependencyInjection\ContainerInterface; /** * Provides a user password reset form. + * + * @internal */ class UserPasswordForm extends FormBase { @@ -60,9 +62,6 @@ class UserPasswordForm extends FormBase { /** * {@inheritdoc} - * - * @param \Symfony\Component\HttpFoundation\Request $request - * The request object. */ public function buildForm(array $form, FormStateInterface $form_state) { $form['name'] = [ @@ -141,7 +140,7 @@ class UserPasswordForm extends FormBase { $mail = _user_mail_notify('password_reset', $account, $langcode); if (!empty($mail)) { $this->logger('user')->notice('Password reset instructions mailed to %name at %email.', ['%name' => $account->getUsername(), '%email' => $account->getEmail()]); - drupal_set_message($this->t('Further instructions have been sent to your email address.')); + $this->messenger()->addStatus($this->t('Further instructions have been sent to your email address.')); } $form_state->setRedirect('user.page');