public function updatePassword($token, $email, $password)
    {
        // Get the token being used.
        $token = $this->tokens->findByToken($token);

        // Make sure the correct email was supplied.
        if ($token->user->email !== $email) {
            return Response::failed('The email does not match this token.')
                           ->route('auth.password.reset');
        }

        // Reset the user's password and let them log in.
        $token->user->resetPassword($password);

        return Response::passed('Password updated.')
                       ->route('auth.login');
    }
public function updatePassword($token, $email, $password)
    {
        // Get the token being used.
        $token = $this->tokens->findByToken($token);

        // Make sure the correct email was supplied.
        if ($token->user->email !== $email) {
            return Response::failed('The email does not match this token.')
                           ->route('auth.password.reset');
        }

        // Reset the user's password and let them log in.
        $token->user->resetPassword($password);

        return Response::passed('Password updated.')
                       ->route('auth.login');
    }
public function updatePassword ( $ token , $ email , $ password ) { // Get the token being used. $ token = $ this -> tokens -> findByToken ( $ token ) ; // Make sure the correct email was supplied. if ( $ token -> user -> email !== $ email ) { return Response :: failed ( 'The email does not match this token.' ) -> route ( 'auth.password.reset' ) ; } // Reset the user's password and let them log in. $ token -> user -> resetPassword ( $ password ) ; return Response :: passed ( 'Password updated.' ) -> route ( 'auth.login' ) ; }
Attempt to update the user's password.

@param string $token    The token string.
@param string $email    The provided email.
@param string $password The new password.

@return Response
Attempt to update the user s password .