Commit 3fd90ee1 authored by Audrey Hamelers's avatar Audrey Hamelers
parent 3e1f3f6d
Pipeline #13416 failed with stages
in 32 seconds
......@@ -116,14 +116,14 @@ const resolvers = {
// Update password reset token
const identity = user.identities.reduce((id, identity) => {
if (identity.email === email) {
if (identity.email.toLowerCase() === email.toLowerCase()) {
return identity
}
return id
}, undefined)
if (!identity) {
throw new Error(`The user is not associated with email ${email}`)
throw new Error(`No user is associated with email ${email}`)
}
let numUpdated = 0
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment