Skip to content

Commit 9a3e295

Browse files
authored
fix(drizzle): incorrect call to getModelName (#1329)
`getSchema` already calls `getModelName`. When custom tables are used, this results in a bug where better-auth can't find the table name.
1 parent c25e130 commit 9a3e295

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/better-auth/src/adapters/drizzle-adapter/drizzle-adapter.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ const createTransform = (
186186
return c[0];
187187
}
188188
await builder;
189-
const schemaModel = getSchema(getModelName(model));
189+
const schemaModel = getSchema(model);
190190
const res = await db
191191
.select()
192192
.from(schemaModel)

0 commit comments

Comments
 (0)