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 rewards.ts

Kiran Kfc90495efa3d
diff --git a/apps/web/lib/zod/schemas/rewards.ts b/apps/web/lib/zod/schemas/rewards.ts
index 303d415437..fc458eabcf 100644
--- a/apps/web/lib/zod/schemas/rewards.ts
+++ b/apps/web/lib/zod/schemas/rewards.ts
@@ -17,22 +17,20 @@ export const COMMISSION_TYPES = [
export const LIMIT_RESET_OPTIONS = [
{ label: "None", value: "" },
- { label: "1 year", value: "12" },
- { label: "6 months", value: "6" },
- { label: "3 months", value: "3" },
- { label: "1 month", value: "1" },
+ { label: "Every year", value: "12" },
+ { label: "Every 6 months", value: "6" },
+ { label: "Every 3 months", value: "3" },
+ { label: "Every month", value: "1" },
] as const;
const payoutResetIntervalSchema = z.coerce
.number()
.nullish()
- .default(null)
.refine(
(val) =>
- val === null ||
- LIMIT_RESET_OPTIONS.some((o) => o.value === val.toString()),
+ !val || LIMIT_RESET_OPTIONS.some((o) => o.value === val.toString()),
{
- message: "Invalid payout reset interval",
+ message: "Invalid payout reset interval.",
},
);