diff --git a/src/installers/next-auth.ts b/src/installers/next-auth.ts index e3d0bdb496..e481631ef6 100644 --- a/src/installers/next-auth.ts +++ b/src/installers/next-auth.ts @@ -33,7 +33,10 @@ export const nextAuthInstaller: Installer = async ({ ); const nextAuthDefinitionSrc = path.join(nextAuthAssetDir, "next-auth.d.ts"); - const nextAuthDefinitionDest = path.join(projectDir, "next-auth.d.ts"); + const nextAuthDefinitionDest = path.join( + projectDir, + "src/types/next-auth.d.ts", + ); await Promise.all([ fs.copy(apiHandlerSrc, apiHandlerDest), diff --git a/template/addons/next-auth/next-auth.d.ts b/template/addons/next-auth/next-auth.d.ts index 6ad5c81d60..a108954cce 100644 --- a/template/addons/next-auth/next-auth.d.ts +++ b/template/addons/next-auth/next-auth.d.ts @@ -1,7 +1,6 @@ import { DefaultSession } from "next-auth"; -/** @see https://github.com/microsoft/TypeScript/issues/12607#issuecomment-502362381 */ -declare module "next-auth/core/types" { +declare module "next-auth" { /** * Returned by `useSession`, `getSession` and received as a prop on the `SessionProvider` React Context */