fix: Emails should be stored and processed in lowercase (#1109)

This commit is contained in:
Tom Moor
2019-12-17 19:44:50 -08:00
committed by GitHub
parent 4511fb7259
commit 89b87c5268
3 changed files with 17 additions and 9 deletions

View File

@@ -20,7 +20,7 @@ router.post('email', async ctx => {
ctx.assertEmail(email, 'email is required');
const user = await User.findOne({
where: { email },
where: { email: email.toLowerCase() },
});
if (user) {