diff --git a/app/routes/book-event.tsx b/app/routes/book-event.tsx index d7b3b4a..828cdae 100644 --- a/app/routes/book-event.tsx +++ b/app/routes/book-event.tsx @@ -44,7 +44,7 @@ export async function loader({ context }: { context: RequestContext }) { }, }); - return preBookedEvents > 3; + return preBookedEvents >= 3; } export default function () { diff --git a/functions/api/events-team/events/new.ts b/functions/api/events-team/events/new.ts index 4742aaf..48b7b9c 100644 --- a/functions/api/events-team/events/new.ts +++ b/functions/api/events-team/events/new.ts @@ -33,7 +33,7 @@ export async function onRequestPost(context: RequestContext) { month: currentMonth, year: currentYear, }, - })) > 3 + })) >= 3 ) return jsonError("Too many events scheduled", 403);