![]() Server : Apache System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64 User : corals ( 1002) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system Directory : /home/corals/syn.corals.io/Corals/core/User/Http/Controllers/Auth/ |
<?php namespace Corals\User\Http\Controllers\Auth; use Corals\Foundation\Http\Controllers\AuthBaseController; use Illuminate\Auth\Events\PasswordReset; use Illuminate\Foundation\Auth\ResetsPasswords; class ResetPasswordController extends AuthBaseController { /* |-------------------------------------------------------------------------- | Password Reset Controller |-------------------------------------------------------------------------- | | This controller is responsible for handling password reset requests | and uses a simple trait to include this behavior. You're free to | explore this trait and override any methods you wish to tweak. | */ use ResetsPasswords; /** * Create a new controller instance. * * @return void */ public function __construct() { $this->corals_middleware = ['guest']; parent::__construct(); } /** * Reset the given user's password. * * @param \Illuminate\Contracts\Auth\CanResetPassword $user * @param string $password * @return void */ protected function resetPassword($user, $password) { $user->password = $password; $user->setRememberToken(\Str::random(60)); $user->forgetProperty('force_reset'); $user->save(); event(new PasswordReset($user)); $this->guard()->login($user); } }