Skip to content

Commit 0bcd32d

Browse files
chore(drizzle): migrate sqliteTable to array API (#13280)
1 parent 90188fa commit 0bcd32d

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

docs/pages/getting-started/adapters/drizzle.mdx

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -302,11 +302,11 @@ export const accounts = sqliteTable(
302302
id_token: text("id_token"),
303303
session_state: text("session_state"),
304304
},
305-
(account) => ({
306-
compoundKey: primaryKey({
305+
(account) => [
306+
primaryKey({
307307
columns: [account.provider, account.providerAccountId],
308308
}),
309-
})
309+
]
310310
)
311311

312312
export const sessions = sqliteTable("session", {
@@ -324,11 +324,11 @@ export const verificationTokens = sqliteTable(
324324
token: text("token").notNull(),
325325
expires: integer("expires", { mode: "timestamp_ms" }).notNull(),
326326
},
327-
(verificationToken) => ({
328-
compositePk: primaryKey({
327+
(verificationToken) => [
328+
primaryKey({
329329
columns: [verificationToken.identifier, verificationToken.token],
330330
}),
331-
})
331+
]
332332
)
333333

334334
export const authenticators = sqliteTable(
@@ -347,11 +347,11 @@ export const authenticators = sqliteTable(
347347
}).notNull(),
348348
transports: text("transports"),
349349
},
350-
(authenticator) => ({
351-
compositePK: primaryKey({
350+
(authenticator) => [
351+
primaryKey({
352352
columns: [authenticator.userId, authenticator.credentialID],
353353
}),
354-
})
354+
]
355355
)
356356
```
357357

0 commit comments

Comments
 (0)