removed ui, docs package
This commit is contained in:
@@ -1,11 +1,10 @@
|
||||
import { getServerSession } from "../../api/auth/[...nextauth]/auth";
|
||||
import { PrismaClient } from "@repo/db";
|
||||
import { prisma } from "@repo/db";
|
||||
import { KursItem } from "../events/_components/item";
|
||||
import { RocketIcon } from "lucide-react";
|
||||
import { eventCompleted } from "@repo/ui";
|
||||
import { eventCompleted } from "../../../helper/events";
|
||||
|
||||
export default async () => {
|
||||
const prisma = new PrismaClient();
|
||||
const page = async () => {
|
||||
const session = await getServerSession();
|
||||
if (!session) return null;
|
||||
const user = await prisma.user.findUnique({
|
||||
@@ -63,10 +62,7 @@ export default async () => {
|
||||
|
||||
const filteredEvents = events.filter((event) => {
|
||||
if (eventCompleted(event, event.participants[0])) return false;
|
||||
if (
|
||||
event.type === "OBLIGATED_COURSE" &&
|
||||
!eventCompleted(event, event.participants[0])
|
||||
)
|
||||
if (event.type === "OBLIGATED_COURSE" && !eventCompleted(event, event.participants[0]))
|
||||
return true;
|
||||
return false;
|
||||
});
|
||||
@@ -95,3 +91,5 @@ export default async () => {
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
export default page;
|
||||
|
||||
Reference in New Issue
Block a user