Skip to content
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

[BUG] Improper error handling for resetPassword #1531

Open
chris-vaimo opened this issue Jun 17, 2024 · 0 comments
Open

[BUG] Improper error handling for resetPassword #1531

chris-vaimo opened this issue Jun 17, 2024 · 0 comments

Comments

@chris-vaimo
Copy link

chris-vaimo commented Jun 17, 2024

Expected Behavior

resetPassword returns error messages from Magento as they are returned from GraphQL.

Actual Behavior

resetPassword throws a hardcoded error, causing the Alokai Magento SDK to return a generic "Internal Server Error" due to lack of handling for such a case.

Possible Solution:

Remove the logic defined in these lines.

if (!result.data.resetPassword) throw new Error("It was not possible to change the user password.");

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant