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.

guard against edge case

Steven Tey0f9499d1d857
diff --git a/apps/web/app/(ee)/api/cron/cleanup/rejected-applications/route.ts b/apps/web/app/(ee)/api/cron/cleanup/rejected-applications/route.ts
index a3d9ffa0bf..2a9190d262 100644
--- a/apps/web/app/(ee)/api/cron/cleanup/rejected-applications/route.ts
+++ b/apps/web/app/(ee)/api/cron/cleanup/rejected-applications/route.ts
@@ -26,6 +26,9 @@ export async function POST(req: Request) {
updatedAt: {
lt: new Date(Date.now() - 1000 * 60 * 60 * 24 * 30),
},
+ commissions: {
+ none: {}, // only delete if there are no commissions
+ },
},
});