From f4bcba82d195fdff1a8e00a79941e9c5a7525211 Mon Sep 17 00:00:00 2001 From: Jared Palmer Date: Fri, 16 Jun 2023 13:30:27 -0400 Subject: [PATCH] Fix up auth --- auth.ts | 3 +-- next-auth.d.ts => index.d.ts | 0 middleware.ts | 4 ++++ 3 files changed, 5 insertions(+), 2 deletions(-) rename next-auth.d.ts => index.d.ts (100%) diff --git a/auth.ts b/auth.ts index e5c8348..5c7c1dd 100644 --- a/auth.ts +++ b/auth.ts @@ -18,9 +18,8 @@ export const { } return token } - // // @ts-ignore + // @TODO // authorized({ request, auth }) { - // if (!request.nextUrl.pathname.startsWith('/share/')) return false // return !!auth?.user // } }, diff --git a/next-auth.d.ts b/index.d.ts similarity index 100% rename from next-auth.d.ts rename to index.d.ts diff --git a/middleware.ts b/middleware.ts index 4afe145..af5b703 100644 --- a/middleware.ts +++ b/middleware.ts @@ -1 +1,5 @@ export { auth as middleware } from './auth' + +export const config = { + matcher: ['/'] +}