mirror of
https://github.com/documenso/documenso.git
synced 2025-11-20 19:51:32 +10:00
render doc list
This commit is contained in:
@ -47,9 +47,12 @@ async function getHandler(req: NextApiRequest, res: NextApiResponse) {
|
||||
let user = await getUserFromToken(req, res);
|
||||
if (!user) return;
|
||||
|
||||
return res
|
||||
.status(200)
|
||||
.json(await prisma.document.findMany({ where: { userId: user?.id } }));
|
||||
return res.status(200).json(
|
||||
await prisma.document.findMany({
|
||||
where: { userId: user?.id },
|
||||
select: { id: true },
|
||||
})
|
||||
);
|
||||
}
|
||||
|
||||
export default defaultHandler({
|
||||
|
||||
Reference in New Issue
Block a user