-
Notifications
You must be signed in to change notification settings - Fork 113
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat : Implement forget password #38
Comments
@Niharika0104 Forget password functionality is already implemented |
@MAVRICK-1 when I click on forget password it's still on the login form.We need to take another form as this might confuse users.If you already have api end points for this and implemented in a fully manner I just make some minor changes as I mentioned. |
@Niharika0104 you can use a modal or where user will enter his/her email or redirect it to the another page where the user will enter it's email |
@Niharika0104 your task is to create that page or modal |
@MAVRICK-1 Thanks I will push the changes as soon as possible |
If Niharika could not complete this can i do it? |
@Niharika0104 any updates ? |
I will push the code changes by tomorrow |
1 similar comment
I will push the code changes by tomorrow |
@MAVRICK-1 I'm done with resolving the issue.I created page for forget password.And email will be sent if user exists.If user doesn't exists then we need to throw error saying email doesn't exists.But this will not be secure.Do you want me to display that message saying user doesn't exists.I have to use firebase admin api for that. |
@MAVRICK-1 can you please update me on this? |
@Niharika0104 Why you making it complicate. Just use try catch. If mail exist then message goes to mail. if mail not exist then in catch use error.message you will get "Firebase: Error (auth/invalid-credential)" this message. simple slice it and show user to mail is not exist create a accout some thing like that message. I hope you understand. If you unable to implement it mention here. @MAVRICK-1 If @Niharika0104 won't implement this can you please assign this to me. |
@Niharika0104 I understand your point. It will not be secure. we have to consider security issues also. So a small suggestion to you. before sending mail. check the mail exists or not. for that you can use signin with mail. then you will get that user exists or not. if exist sent mail else ask for login. I hope you got my point. I am just suggesting you why because website security and data security is also important right. Happy coding. have a good gssoc journey |
@Hemu21 I'm not making it complicated and irrespective of mail exists or not it's returns undefined.So this is the issue,we are not using signinwithemail method which firebase provides to get that error.Firebase are returning undefined for security reasons.Hope u got |
@Niharika0104 did you understand what I am telling? |
@Hemu21 In signin method we also need to know password dude and in reset password user doesn't know right password.Well I can know the user email exists or not by using firebase admin sdk |
@Niharika0104 you can put dummmy or some other string. anyway it's you wish how you implement is. I just gave you a suggestion. |
@Hemu21 I know the solution for this issue.I just want to get clarification from @MAVRICK-1 whether this message email doesn't exists is required or not.If it is required then I will add that message using firebase admin sdk else I will ommit and also show that mail has been sent even if user is not registered (and obviously mail won't be sent though) |
@Hemu21 @Niharika0104 plz don't argue , @Niharika0104 I want something like this Link over here a modal appears , you can redirect to another page also if you want , if the link send to the user it will display link send check your email , if user didn't exist it will show user don't exist |
@MAVRICK-1 Thanks a lot for clarifying that's exactly why I wanted to hear.So according to the link you provided the password reset mail will be sent irrespective of email is registered or not.I will be doing the same in this application as well.@MAVRICK-1 Congratulations you got accepted into gsoc! |
@Niharika0104 For now we haven't integrated , email authentication till now . So there is no way to know the email really exist or not , If email exist in fire authentication db it will send it to the mail or if not it will return a error . In future i will implement passwordless login , Which will remove this password problem , you can see the feature on the above given website . |
@MAVRICK-1 it doesn't return error when user doesn't exists🙂and it is always returning undefined.Anyways I will do what's been suggested.Thanks for clarifying again. |
@Niharika0104 link go through the documentation . |
@Niharika0104 https://github.com/MAVRICK-1/e-commerce_website/blob/dev/src/pages/SignIn/index.js#L150-L162 link for forget password function. Common Errors in
|
Description:
The application currently lacks the "Forgot Password" feature, which is crucial for user account recovery. This issue is to implement the necessary pages and functionality required for the "Forgot Password" feature.
Tasks:
Create Forgot Password Page: Develop a new page or modal for the "Forgot Password" functionality.
Backend Logic for Password Reset: Develop backend logic to handle password reset requests and send reset instructions to the user's email.
The text was updated successfully, but these errors were encountered: