Papermark is the open-source DocSend alternative and secure data rooms with built-in analytics and custom domains.
fix: limit api invitations
Marc Seitz3c6c0ad5f896
diff --git a/pages/api/teams/[teamId]/datarooms/[id]/users/index.ts b/pages/api/teams/[teamId]/datarooms/[id]/users/index.tsindex 4d738278..554bf3ee 100644--- a/pages/api/teams/[teamId]/datarooms/[id]/users/index.ts+++ b/pages/api/teams/[teamId]/datarooms/[id]/users/index.ts@@ -30,6 +30,12 @@ export default async function handle(return res.status(400).json("Email is missing in request body");}+ if (emails.length > 5) {+ return res+ .status(400)+ .json("You can only send invitations to 5 emails at a time.");+ }+try {const team = await prisma.team.findUnique({where: {