fix: add composite index on SecondaryEmail for email verification queries (#27357)

Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
Alex van AndelandDevin AI authored and GitHub committed 2026-01-28 14:53:31 -03:00
1 parent 620445d85f
commit 906ba99d3c
2 files changed
+3

No files matched your search

@@ -0,0 +1,2 @@
-- CreateIndex
CREATE INDEX IF NOT EXISTS "SecondaryEmail_email_emailVerified_idx" ON "public"."SecondaryEmail"("email", "emailVerified");
+1
View File
@@ -2172,6 +2172,7 @@ model SecondaryEmail {
@@unique([email])
@@unique([userId, email])
@@index([userId])
@@index([email, emailVerified])
}
// Needed to store tasks that need to be processed by a background worker or Tasker