public function getViewedConversationCountForConsole($userId, $messageList) { $convList = array(); foreach ($messageList as $messageData) { if (!in_array($messageData['convId'], $convList)) { $convList[] = $messageData['convId']; } } return $this->conversationDao->getViewedConversationCountForConsole($userId, $convList); }