validate([Fortify::email() => 'required|email']); if (config('fortify.lowercase_usernames') && $request->has(Fortify::email())) { $request->merge([ Fortify::email() => Str::lower($request->{Fortify::email()}), ]); } // We will send the password reset link to this user. Once we have attempted // to send the link, we will examine the response then see the message we // need to show to the user. Finally, we'll send out a proper response. $status = $this->broker()->sendResetLink( $request->only(Fortify::email()) ); return $status == Password::RESET_LINK_SENT ? app(SuccessfulPasswordResetLinkRequestResponse::class, ['status' => $status]) : app(FailedPasswordResetLinkRequestResponse::class, ['status' => $status]); } /** * Get the broker to be used during password reset. * * @return \Illuminate\Contracts\Auth\PasswordBroker */ protected function broker(): PasswordBroker { return Password::broker(config('fortify.passwords')); } }