Add back vc auth temporarily to unblock things
This commit is contained in:
parent
07c2e7d36a
commit
177b2cc210
20 changed files with 350 additions and 40 deletions
|
|
@ -1,12 +1,12 @@
|
|||
"use server";
|
||||
|
||||
import { getServerSession } from "next-auth";
|
||||
import { prisma } from "@/lib/prisma";
|
||||
import { getServerSession } from "@/lib/session/get-server-session";
|
||||
import { revalidatePath } from "next/cache";
|
||||
import { authOptions } from "@/app/api/auth/[...nextauth]/route";
|
||||
|
||||
export async function removeChat({ id, path }: { id: string; path: string }) {
|
||||
const session = await getServerSession(authOptions);
|
||||
const session = await getServerSession();
|
||||
|
||||
const userId = session?.user?.email;
|
||||
if (!userId || !id) {
|
||||
throw new Error("Unauthorized");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue