prettier all the things

This commit is contained in:
Thomas Ruoff
2022-02-19 23:18:49 +01:00
parent 4b918af23e
commit 9886cf29d2
28 changed files with 433 additions and 428 deletions

View File

@@ -14,23 +14,22 @@ export type ServerSideRecentBooking = {
}
}
export const getServerSideRecentBookings = async (): Promise<
ServerSideRecentBooking
> => {
const bookings = await getBookings({
startDateGreaterThan: startOfYear(nowInTz()).toISOString(),
})
export const getServerSideRecentBookings =
async (): Promise<ServerSideRecentBooking> => {
const bookings = await getBookings({
startDateGreaterThan: startOfYear(nowInTz()).toISOString(),
})
// TODO: hack, not sure why _id is not serilizable
const bookingsJSON = JSON.parse(
JSON.stringify(bookings.map((b) => b.toJSON()))
) as object[]
return {
props: {
bookings: bookingsJSON,
},
// TODO: hack, not sure why _id is not serilizable
const bookingsJSON = JSON.parse(
JSON.stringify(bookings.map((b) => b.toJSON()))
) as object[]
return {
props: {
bookings: bookingsJSON,
},
}
}
}
export const getServerSideBooking = async (
context: any