diff --git a/app/api/chat/route.ts b/app/api/chat/route.ts index 5166430..8d9b3c5 100644 --- a/app/api/chat/route.ts +++ b/app/api/chat/route.ts @@ -14,7 +14,7 @@ const openai = new OpenAI({ export async function POST(req: Request) { const json = await req.json() const { messages, previewToken } = json - const userId = (await auth())?.user.id // this doesn't seem to work getting the id + const userId = (await auth())?.user.id if (!userId) { return new Response('Unauthorized', {