Skip to content

armgit / dub

Public Imported from GitHub
0

The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.

Update route.ts

Kiran K53212b5778eb
diff --git a/apps/web/app/api/cron/links/sync-tinybird/route.ts b/apps/web/app/api/cron/links/sync-tinybird/route.ts
index 31bf7ceb55..ae08ad8053 100644
--- a/apps/web/app/api/cron/links/sync-tinybird/route.ts
+++ b/apps/web/app/api/cron/links/sync-tinybird/route.ts
@@ -7,6 +7,8 @@ import { z } from "zod";
export const dynamic = "force-dynamic";
+const MAX_LINKS_PER_BATCH = 500;
+
const schema = z.object({
folderId: z.string(),
});
@@ -65,7 +67,7 @@ export async function POST(req: Request) {
orderBy: {
id: "asc",
},
- take: 1,
+ take: MAX_LINKS_PER_BATCH,
});
await recordLink(