Change access_token type to undefined instead of null
This commit is contained in:
parent
b4503db688
commit
ca2eef3d08
1 changed files with 2 additions and 2 deletions
4
auth.ts
4
auth.ts
|
@ -7,7 +7,7 @@ const prisma = new PrismaClient()
|
|||
|
||||
declare module "next-auth" {
|
||||
interface Session {
|
||||
access_token: string | null;
|
||||
access_token: string | undefined;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -33,7 +33,7 @@ export const { handlers, auth, signIn, signOut } = NextAuth({
|
|||
},
|
||||
});
|
||||
|
||||
let accessToken: string | null = null;
|
||||
let accessToken: string | undefined = undefined;
|
||||
if (getToken) {
|
||||
accessToken = getToken.access_token!;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue