Accommodations in trash affected on the search

WordPress Booking Solutions Forums WordPress Plugins Booking Calendar Accommodations in trash affected on the search

Viewing 1 post (of 1 total)
  • Author
    Posts
  • #1870885

    Hello,

    in BookingRulesData::getBlocksByDate(), when the room type has trashed rooms, the filter loop reuses $dateStr as its loop variable and overwrites the requested date.
    As a result, the function returns the blocks of the last day of the month instead of the requested day, so blocked accommodations show as available in search.
    So the accommodations in trash status affected on the search which I guess is a bug. For now I have deleted the trash elements that resolved the case.
    Further recommendation to renaming the loop variable (e.g. foreach ( array_keys( $blocksByDate ) as $day )) fixes it.

    Regards, D

Viewing 1 post (of 1 total)
  • You must be logged in to reply to this topic.