This commit is contained in:
2025-04-08 04:05:57 +02:00
parent cdd9f01214
commit 87832f46a3
14 changed files with 155 additions and 42 deletions

8
src/app/actions.ts Normal file
View File

@@ -0,0 +1,8 @@
'use server'
import { auth } from "@clerk/nextjs/server"
import { env } from "~/env"
export async function isAdmin() {
const userid = (await auth()).userId
return (userid == env.ADMIN_USER_CLERK_ID)
}