lunar icon indicating copy to clipboard operation
lunar copied to clipboard

Display error message if user reset password with an email that is not registered in the system.

Open Aslam97 opened this issue 4 years ago • 2 comments

Is your feature request related to a problem? Please describe. If the user resets the password and then enters the wrong email when clicking the "send reset email" button, there is no notification telling the user that the email is not registered in the system. its doing nothing.

Describe the solution you'd like option 1. add unique email validation for staff something like exists:lunar_staff,email option 2. use custom validation error message something like this

    public function sendResetEmail()
    {
        $this->validate();

        $staff = Staff::whereEmail($this->email)->first();

        if (is_null($staff)) {
            $this->addError('email', 'The email address you entered is not registered with us.');
        }

        // ...
    }

Aslam97 avatar Oct 28 '22 06:10 Aslam97

Isn’t it common practice to report back that an email has been sent regardless of it exists, not to tell the end user that it does or doesn’t exist.

SiCoUK avatar Oct 28 '22 21:10 SiCoUK

Isn’t it common practice to report back that an email has been sent regardless of it exists, not to tell the end user that it does or doesn’t exist.

yes i agreed. but the current lunar when the user enters the wrong email there is no report back to the user. only if the user filled the correct email then there is a success notification Password reset sent.

Aslam97 avatar Oct 28 '22 22:10 Aslam97