mirror of
https://github.com/better-auth/better-auth.git
synced 2026-05-28 01:46:45 -05:00
fix: twofactor id constriant fail
This commit is contained in:
@@ -76,9 +76,10 @@ export const twoFactor = (options?: TwoFactorOptions) => {
|
||||
twoFactorEnabled: true,
|
||||
});
|
||||
|
||||
const res = await ctx.context.adapter.create({
|
||||
await ctx.context.adapter.create({
|
||||
model: opts.twoFactorTable,
|
||||
data: {
|
||||
id: ctx.context.uuid(),
|
||||
secret: encryptedSecret,
|
||||
backupCodes: backupCodes.encryptedBackupCodes,
|
||||
userId: user.id,
|
||||
|
||||
Reference in New Issue
Block a user