mirror of
https://github.com/documenso/documenso.git
synced 2025-11-13 00:03:33 +10:00
feat: google auth without schema change
This commit is contained in:
23
packages/lib/types/next-auth.d.ts
vendored
Normal file
23
packages/lib/types/next-auth.d.ts
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
import type { User as PrismaUser } from '@prisma/client';
|
||||
import type { DefaultUser } from 'next-auth';
|
||||
|
||||
declare module 'next-auth' {
|
||||
interface Session {
|
||||
user: User;
|
||||
}
|
||||
|
||||
interface User extends Omit<DefaultUser, 'id' | 'image'> {
|
||||
id: PrismaUser['id'];
|
||||
email?: PrismaUser['email'];
|
||||
name?: PrismaUser['name'];
|
||||
emailVerified?: PrismaUser['emailVerified'];
|
||||
}
|
||||
}
|
||||
|
||||
declare module 'next-auth/jwt' {
|
||||
interface JWT {
|
||||
id: string | number;
|
||||
name?: string | null;
|
||||
email: string | null;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user