diff --git a/lib/getServerSideProps.ts b/lib/getServerSideProps.ts index f3a3203..63bc65c 100644 --- a/lib/getServerSideProps.ts +++ b/lib/getServerSideProps.ts @@ -38,6 +38,8 @@ export const getServerSideBooking = async ( const uuid = Array.isArray(uuids) ? uuids[0] : uuids const booking = await getBookingByUUID(uuid) + console.log(booking.createdAt); + if (!booking) { res.statusCode = 404 res.end() @@ -45,6 +47,10 @@ export const getServerSideBooking = async ( } return { - props: { booking }, + props: { booking: { + ...booking, + createdAt: booking.createdAt.toISOString(), + updatedAt: booking.updatedAt.toISOString(), + }}, } }