Skip to content

Commit 380ea88

Browse files
committed
fix: type cast DrizzleAdapter due to typescript issues
1 parent ffe811c commit 380ea88

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

cli/template/extras/src/server/auth-app/with-drizzle.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import {
44
type DefaultSession,
55
type NextAuthOptions,
66
} from "next-auth";
7+
import { type Adapter } from "next-auth/adapters";
78
import DiscordProvider from "next-auth/providers/discord";
89

910
import { env } from "~/env";
@@ -46,7 +47,7 @@ export const authOptions: NextAuthOptions = {
4647
},
4748
}),
4849
},
49-
adapter: DrizzleAdapter(db, mysqlTable),
50+
adapter: DrizzleAdapter(db, mysqlTable) as Adapter,
5051
providers: [
5152
DiscordProvider({
5253
clientId: env.DISCORD_CLIENT_ID,

cli/template/extras/src/server/auth-pages/with-drizzle.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import {
55
type DefaultSession,
66
type NextAuthOptions,
77
} from "next-auth";
8+
import { type Adapter } from "next-auth/adapters";
89
import DiscordProvider from "next-auth/providers/discord";
910

1011
import { env } from "~/env";
@@ -47,7 +48,7 @@ export const authOptions: NextAuthOptions = {
4748
},
4849
}),
4950
},
50-
adapter: DrizzleAdapter(db, mysqlTable),
51+
adapter: DrizzleAdapter(db, mysqlTable) as Adapter,
5152
providers: [
5253
DiscordProvider({
5354
clientId: env.DISCORD_CLIENT_ID,

0 commit comments

Comments
 (0)