diff --git a/apps/web/pages/event-types/[type].tsx b/apps/web/pages/event-types/[type].tsx index eb645075d2..665767a537 100644 --- a/apps/web/pages/event-types/[type].tsx +++ b/apps/web/pages/event-types/[type].tsx @@ -324,8 +324,8 @@ const EventTypePage = (props: inferSSRProps) => { ); const [tokensList, setTokensList] = useState>([]); - const defaultSeats = 2; - const defaultSeatsInput = 6; + const defaultSeatsPro = 6; + const minSeats = 2; const [enableSeats, setEnableSeats] = useState(!!eventType.seatsPerTimeSlot); const periodType = @@ -1672,7 +1672,7 @@ const EventTypePage = (props: inferSSRProps) => { if (e?.target.checked) { setEnableSeats(true); // Want to disable individuals from taking multiple seats - formMethods.setValue("seatsPerTimeSlot", defaultSeats); + formMethods.setValue("seatsPerTimeSlot", defaultSeatsPro); formMethods.setValue("disableGuests", true); formMethods.setValue("requiresConfirmation", false); } else { @@ -1731,13 +1731,13 @@ const EventTypePage = (props: inferSSRProps) => { @@ -1757,22 +1757,14 @@ const EventTypePage = (props: inferSSRProps) => { return; } if (val.value === -1) { - formMethods.setValue( - "seatsPerTimeSlot", - defaultSeatsInput - ); + formMethods.setValue("seatsPerTimeSlot", minSeats); } else { - formMethods.setValue( - "seatsPerTimeSlot", - val!.value - ); + formMethods.setValue("seatsPerTimeSlot", val.value); } }} defaultValue={{ - value: eventType.seatsPerTimeSlot || defaultSeats, - label: `${ - eventType.seatsPerTimeSlot || defaultSeats - }`, + value: eventType.seatsPerTimeSlot || minSeats, + label: `${eventType.seatsPerTimeSlot || minSeats}`, }} options={selectSeatsPerTimeSlotOptions} />