fix: [object object] problem (#24643)

* fix: object problem

* revert and improve logic

* revert

* fix

* Update apps/web/modules/bookings/views/bookings-single-view.tsx

Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>

---------

Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
Co-authored-by: Pallav <90088723+Pallava-Joshi@users.noreply.github.com>
This commit is contained in:
Saurabh Singh
2025-12-02 02:32:51 +00:00
committed by GitHub
co-authored by cubic-dev-ai[bot] Pallav
parent f33edb2b99
commit 65893ae943
3 changed files with 3 additions and 3 deletions
@@ -595,7 +595,7 @@ export default function Success(props: PageProps) {
)}
<div className="font-medium">{t("what")}</div>
<div className="col-span-2 mb-6 break-words last:mb-0" data-testid="booking-title">
{isRoundRobin ? bookingInfo.title : eventName}
{isRoundRobin ? (typeof bookingInfo.title === 'string' ? bookingInfo.title : eventName) : eventName}
</div>
<div className="font-medium">{t("when")}</div>
<div className="col-span-2 mb-6 last:mb-0">
@@ -62,7 +62,7 @@ export default function Bookings(props: { calUsername: string; calEmail: string
<h4>What</h4>
</div>
<div>
<p>{booking.title}</p>
<p>{typeof booking.title === 'string' ? booking.title : 'Untitled Event'}</p>
</div>
</div>
<div className="flex gap-[70px]">
+1 -1
View File
@@ -15,7 +15,7 @@ export default class EventCancelledSMS extends SMSManager {
const messageText = `${t("hey_there")} ${attendee.name}, ${t("event_request_cancelled")}\n\n${t(
"event_cancelled_subject",
{
title: this.calEvent.title,
title: typeof this.calEvent.title === 'string' ? this.calEvent.title : 'Untitled Event',
date: this.getFormattedDate(attendee.timeZone, attendee.language.locale),
interpolation: { escapeValue: false },
}