public function countUnreadMessagesForConversationList($conversationIdList, $userId) { if (count($conversationIdList) == 0) { return array(); } $list = $this->messageDao->countUnreadMessagesForConversationList($conversationIdList, $userId); $result = array(); foreach ($list as $item) { $result[$item['conversationId']] = $item['count']; } return $result; }