fix(auth): add account issuer migration
This commit is contained in:
+2
-4
@@ -62,6 +62,7 @@ export const accounts = pgTable(
|
||||
"account",
|
||||
{
|
||||
id: text("id").primaryKey(),
|
||||
issuer: text("issuer").notNull(),
|
||||
accountId: text("account_id").notNull(),
|
||||
providerId: text("provider_id").notNull(),
|
||||
userId: text("user_id")
|
||||
@@ -81,10 +82,7 @@ export const accounts = pgTable(
|
||||
...timestamps,
|
||||
},
|
||||
(table) => [
|
||||
uniqueIndex("account_provider_unique").on(
|
||||
table.providerId,
|
||||
table.accountId,
|
||||
),
|
||||
uniqueIndex("account_issuer_unique").on(table.issuer, table.accountId),
|
||||
index("account_user_id_idx").on(table.userId),
|
||||
],
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user