【发布时间】:2020-09-30 11:17:11
【问题描述】:
如果用户尝试使用现有电子邮件创建帐户,则调用 firebase.auth().createUserWithEmailAndPassword(email, password) 会导致 "QUOTA_EXCEEDED : Exceeded quota for email lookup."。
这是我的代码(使用"firebase": "7.6.2"):
firebase.auth().createUserWithEmailAndPassword(email, password)
.then(result => {
result.user.sendEmailVerification(actionCodeSettings);
})
.catch(error => {
console.log(error);
// Handling error for user
});
错误已正确处理。错误被捕捉到
"error": {
"code": 400,
"message": "EMAIL_EXISTS",
"errors": [
{
"message": "EMAIL_EXISTS",
"domain": "global",
"reason": "invalid"
}
]
}
}
尽管如此,firebase 仍在调用 createAuthUri 来创建 IdP 用来对用户进行身份验证的 URI。此调用在循环中触发,直到达到配额为止。
有没有人有同样的问题?如何取消createAuthUri 的来电,避免超额运行?
【问题讨论】:
-
嗨,这很奇怪。我使用了您的相同代码,并且没有收到任何类型的配额超出错误。我刚刚收到一个错误
The email address is already in use by another account.。您是否在此用户创建的上下文中执行其他任何操作,例如循环?
标签: javascript reactjs firebase firebase-authentication google-identity-toolkit