forgot-form-fox
This commit is contained in:
parent
90cf0a9e10
commit
27711d7e99
|
@ -65,21 +65,16 @@ export const ForgotPasswordForm = () => {
|
||||||
email: email(),
|
email: email(),
|
||||||
redirect_uri: window.location.origin,
|
redirect_uri: window.location.origin,
|
||||||
})
|
})
|
||||||
if (data) {
|
console.debug('[ForgotPasswordForm] authorizer response:', data)
|
||||||
console.debug('[ForgotPasswordForm] authorizer response:', data)
|
setMessage(data.message)
|
||||||
setMessage(data.message)
|
|
||||||
}
|
console.warn(errors)
|
||||||
if (errors) {
|
if (errors.some((e) => e.cause === 'user_not_found')) {
|
||||||
console.warn(errors)
|
setIsUserNotFound(true)
|
||||||
if (errors) {
|
return
|
||||||
const error: Error = errors[0]
|
} else {
|
||||||
if (error.cause === 'user_not_found') {
|
const errorText = errors.map((e) => e.message).join(' ') // FIXME
|
||||||
setIsUserNotFound(true)
|
setSubmitError(errorText)
|
||||||
return
|
|
||||||
} else {
|
|
||||||
setSubmitError(error.message)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error(error)
|
console.error(error)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user