revert style: clean up code with prettier and eslint
This commit is contained in:
remco committed 2026-07-12 21:02:03 +02:00
1 parent 27de078f54
commit e85e4d74ea
378 files changed
+20710 -22428

No files matched your search

+13 -14
View File
@@ -1,21 +1,20 @@
import { notFound } from "next/navigation";
import { prisma } from "@/lib/prisma";
import { notFound } from 'next/navigation'
import { prisma } from '@/lib/prisma'
export async function loadRoom(id: string) {
const roomId = parseInt(id, 10);
if (Number.isNaN(roomId)) notFound();
const roomId = parseInt(id, 10)
if (Number.isNaN(roomId)) notFound()
const room = await prisma.rooms.findUnique({
where: { id: roomId },
});
})
if (!room) notFound();
const owner =
room.ownerId > 0
? await prisma.user.findUnique({
where: { id: room.ownerId },
select: { id: true, username: true, look: true },
})
: null;
return { ...room, owner };
if (!room) notFound()
const owner = room.ownerId > 0
? await prisma.user.findUnique({
where: { id: room.ownerId },
select: { id: true, username: true, look: true },
})
: null
return { ...room, owner }
}