feat: contain logic for selecting price at the top level instead of on individual room card

This commit is contained in:
Joakim Jäderberg
2024-11-20 11:25:11 +01:00
parent dfdbdb7621
commit d32a595e2e
9 changed files with 63 additions and 106 deletions

View File

@@ -40,14 +40,10 @@ export async function NoRoomsAlert({
})
)
if (!availability) {
if (!availability || availabilityError) {
return null
}
if (availabilityError) {
// TODO: Handle error
}
const noRoomsAvailable = availability.roomConfigurations.reduce(
(acc, room) => {
return acc && room.status === "NotAvailable"