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.

Amount must be greater than 0

Kiran K67a84847eceb
diff --git a/apps/web/lib/zod/schemas/commissions.ts b/apps/web/lib/zod/schemas/commissions.ts
index c16ea2322d..b074d94c5a 100644
--- a/apps/web/lib/zod/schemas/commissions.ts
+++ b/apps/web/lib/zod/schemas/commissions.ts
@@ -186,7 +186,7 @@ export const CLAWBACK_REASONS_MAP = Object.fromEntries(
export const createClawbackSchema = z.object({
workspaceId: z.string(),
partnerId: z.string(),
- amount: z.number().min(0, "Amount must be positive."),
+ amount: z.number().gt(0, "Amount must be greater than 0."),
description: z.enum(
CLAWBACK_REASONS.map((r) => r.value) as [string, ...string[]],
),