The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.
TypeScript clickhousemysqlnextjsopen-sourceplanetscaleprismatailwindcsstinybirdtypescriptupstashvercel
Update add-edit-bounty-sheet.tsx
Kiran K7b88c268cfa2
diff --git a/apps/web/app/app.dub.co/(dashboard)/[slug]/(ee)/program/bounties/add-edit-bounty-sheet.tsx b/apps/web/app/app.dub.co/(dashboard)/[slug]/(ee)/program/bounties/add-edit-bounty-sheet.tsxindex 0371bd0552..b7e4777c50 100644--- a/apps/web/app/app.dub.co/(dashboard)/[slug]/(ee)/program/bounties/add-edit-bounty-sheet.tsx+++ b/apps/web/app/app.dub.co/(dashboard)/[slug]/(ee)/program/bounties/add-edit-bounty-sheet.tsx@@ -263,19 +263,17 @@ function BountySheetContent({ setIsOpen, bounty }: BountySheetProps) {// Decide if the submit button should be disabledconst validationError = useMemo(() => {- const effectiveStartDate = startsAt || new Date();-- if (effectiveStartDate < new Date()) {+ if (startsAt && startsAt < new Date()) {return "Please choose a start date that is in the future.";}+ const effectiveStartDate = startsAt || new Date();+if (endsAt && endsAt <= effectiveStartDate) {return `Please choose an end date that is after the start date (${formatDate(effectiveStartDate)}).`;}if (submissionWindow) {- console.log({ startsAt, endsAt, submissionWindow });-if (!endsAt) {return "An end date is required to determine when the submission window opens.";}