chore: adds check for lowercase emails (#1693)

This commit is contained in:
Dhruwang Jariwala
2023-11-28 19:58:02 +05:30
committed by GitHub
parent 6be825184a
commit b40ddbf47b
2 changed files with 2 additions and 2 deletions

View File

@@ -48,7 +48,7 @@ export const SigninForm = ({
try {
const signInResponse = await signIn("credentials", {
callbackUrl: searchParams?.get("callbackUrl") || "/",
email: data.email,
email: data.email.toLowerCase(),
password: data.password,
...(totpLogin && { totpCode: data.totpCode }),
...(totpBackup && { backupCode: data.backupCode }),

View File

@@ -7,7 +7,7 @@ const VerificationPageSchema = z.string().email();
export default function VerificationPage(params) {
const email = params.searchParams.email;
try {
const parsedEmail = VerificationPageSchema.parse(email);
const parsedEmail = VerificationPageSchema.parse(email).toLowerCase();
return (
<FormWrapper>
<>