mirror of
https://github.com/Drop-OSS/drop.git
synced 2025-11-13 00:02:37 +10:00
12 lines
342 B
TypeScript
12 lines
342 B
TypeScript
import prisma from "~/server/internal/db/database";
|
|
|
|
export default defineEventHandler(async (h3) => {
|
|
const user = await h3.context.session.getAdminUser(h3);
|
|
if (!user) throw createError({ statusCode: 403 });
|
|
|
|
await runTask("cleanup:invitations");
|
|
|
|
const invitations = await prisma.invitation.findMany({});
|
|
return invitations;
|
|
});
|