diff --git a/file/lib/data/room/Room.class.php b/file/lib/data/room/Room.class.php index 67e0803..deccce5 100644 --- a/file/lib/data/room/Room.class.php +++ b/file/lib/data/room/Room.class.php @@ -179,9 +179,9 @@ public function getUsers() { $userList->readObjects(); $users = $userList->getObjects(); - foreach ($users as $user) { + foreach ($users as $userID => $user) { if (!isset(self::$users[$user->chatRoomID])) self::$users[$user->chatRoomID] = array(); - self::$users[$user->chatRoomID][] = $user; + self::$users[$user->chatRoomID][$userID] = $user; } } if (!isset(self::$users[$this->roomID])) self::$users[$this->roomID] = array();