Fixes 0 issue by boolean cast (#3004)

pull/2999/head^2
Alex van Andel 2022-06-07 17:10:30 +01:00 committed by GitHub
parent 55d6f1ee35
commit 5a84adcd8a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -122,7 +122,7 @@ const AvailableTimes: FC<AvailableTimesProps> = ({
brand === "#fff" || brand === "#ffffff" ? "border-brandcontrast" : "border-brand"
)}>
{slot.time.format(timeFormat)}
{seatsPerTimeSlot && <p className={`text-sm`}>{t("booking_full")}</p>}
{!!seatsPerTimeSlot && <p className={`text-sm`}>{t("booking_full")}</p>}
</div>
) : (
<Link href={bookingUrl}>
@ -133,7 +133,7 @@ const AvailableTimes: FC<AvailableTimesProps> = ({
)}
data-testid="time">
{dayjs.tz(slot.time, timeZone()).format(timeFormat)}
{seatsPerTimeSlot && (
{!!seatsPerTimeSlot && (
<p
className={`${
slot.attendees && slot.attendees / seatsPerTimeSlot >= 0.8