X-Git-Url: https://git.rohieb.name/iserv-mod-room-reservation.git/blobdiff_plain/414012a37fe24e583c60f576dc858faf8813dfc5..ada3bd52df2712a6c6ead81aa646d5ec47aeeca2:/includes/mod_roomReservationBookingsManager.inc diff --git a/includes/mod_roomReservationBookingsManager.inc b/includes/mod_roomReservationBookingsManager.inc index 722c164..124068d 100644 --- a/includes/mod_roomReservationBookingsManager.inc +++ b/includes/mod_roomReservationBookingsManager.inc @@ -144,7 +144,12 @@ class mod_roomReservationBookingsManager { ($ob->getUid() == null and !$this->oCfg->userCanBook())) { throw new AccessException(MOD_ROOM_RESERVATION_ERROR_ACCESS_DENIED); } - + + // test if room is whitelisted + if(!$this->oCfg->isRoomWhitelisted($ob->getRoom())) { + throw new Exception(MOD_ROOM_RESERVATION_ERROR_ROOM_NOT_WHITELISTED); + } + $strWhere = null; $strLog = "";