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

to verify: Customer email address normalization not being done on update #2449

Closed
michaelbromley opened this issue Oct 13, 2023 · 0 comments
Closed
Assignees
Labels
type: bug 🐛 Something isn't working

Comments

@michaelbromley
Copy link
Member

Describe the bug
Ran into a strange situation in prod where a customer was having trouble resetting password.

It looks like the sequence was:

  1. Customer changed email address via shop api to an address with upper & lowercase characters
  2. Customer verified this email address successfully
  3. Later on they wanted to reset their password, and could not
  4. When I attempted to manually use the password reset token, I was getting strange errors:
{
    "errors": [
        {
            "message": "Unexpected error value: { __typename: \"InvalidCredentialsError\", errorCode: \"INVALID_CREDENTIALS_ERROR\", message: \"INVALID_CREDENTIALS_ERROR\", authenticationError: \"\" }",
            "locations": [
                {
                    "line": 2,
                    "column": 3
                }
            ],
            "path": [
                "resetPassword"
            ]
        }
    ],
    "data": null
}

My suspicion is that it is because of the uppercase chars in the email address. On account creation, we normalize to lowercase using the normalizeEmailAddress() function, but I think this is missing for updates

  • via the Shop API email address change flow
  • via manual changes via the Admin API
@michaelbromley michaelbromley added the type: bug 🐛 Something isn't working label Oct 13, 2023
@michaelbromley michaelbromley self-assigned this Oct 13, 2023
@michaelbromley michaelbromley moved this to 📋 Backlog in Vendure OS Roadmap Oct 13, 2023
@michaelbromley michaelbromley moved this from 📋 Backlog to 🔖 Ready in Vendure OS Roadmap Oct 17, 2023
@michaelbromley michaelbromley moved this from 🔖 Ready to ✅ Done in Vendure OS Roadmap Oct 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug 🐛 Something isn't working
Projects
Status: 🚀 Shipped
Development

No branches or pull requests

1 participant