Skip to content

Commit

Permalink
chore: remove unnecessary annotations & add indices to prisma schema (r…
Browse files Browse the repository at this point in the history
…eworkd#300)

* chore: remove unnecessary annotations

* chore: add index to userId in account model
  • Loading branch information
w00ing authored Apr 22, 2023
1 parent aa64446 commit cf3f620
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions prisma/schema.prisma
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
generator client {
provider = "prisma-client-js"
previewFeatures = ["ReferentialIntegrity"]
provider = "prisma-client-js"
}

datasource db {
Expand All @@ -26,6 +25,7 @@ model Account {
user User @relation(fields: [userId], references: [id], onDelete: Cascade)
@@unique([provider, providerAccountId])
@@index([userId])
}

model Session {
Expand All @@ -34,6 +34,8 @@ model Session {
userId String
expires DateTime
user User @relation(fields: [userId], references: [id], onDelete: Cascade)
@@index([userId])
}

model User {
Expand Down

0 comments on commit cf3f620

Please sign in to comment.