}
}
// Add occupant count updates to packet
// TODO: Refactor out into a different class
MultiUserChatManager mucManager = XMPPServer.getInstance().getMultiUserChatManager();
for (String roomJid : presenceRoomJids) {
JID jid = new JID(roomJid);
MultiUserChatService mucService = mucManager.getMultiUserChatService(jid);
MUCRoom room = mucService.getChatRoom(jid.getNode());
// Not count room owners as occupants
int totalOccupants = room.getOccupantsCount();
for (String owner : room.getOwners()) {
try {