mirror of
https://github.com/wbbaddons/Tims-Chat.git
synced 2024-10-31 14:10:08 +00:00
Fix MessageLogPage when temporary rooms exist
This commit is contained in:
parent
017487bbe8
commit
0ef6dbb36b
@ -124,8 +124,7 @@ public function readParameters() {
|
||||
$this->rooms = \chat\data\room\RoomCache::getInstance()->getRooms();
|
||||
|
||||
foreach ($this->rooms as $id => $room) {
|
||||
if (!$room->permanent)
|
||||
unset($this->rooms[$key]);
|
||||
if (!$room->permanent) unset($this->rooms[$key]);
|
||||
}
|
||||
|
||||
if (isset($_REQUEST['id'])) $this->roomID = intval($_REQUEST['id']);
|
||||
@ -134,6 +133,7 @@ public function readParameters() {
|
||||
$this->room = \chat\data\room\RoomCache::getInstance()->getRoom($this->roomID);
|
||||
|
||||
if (!$this->room) throw new \wcf\system\exception\IllegalLinkException();
|
||||
if (!$this->room->permanent) throw new \wcf\system\exception\PermissionDeniedException();
|
||||
|
||||
if (isset($_REQUEST['date'])) $date = $_REQUEST['date'].' 00:00:00';
|
||||
else $date = 'today 00:00:00';
|
||||
|
Loading…
Reference in New Issue
Block a user