*
check this given two users is already make a conversation
public isExistsAmongTwoUsers ( $user1, $user2 ) | ||
$user1 | ||
$user2 |
/** * make sure is this conversation exist for this user with currently loggedin user. * * @param int $userId * @return bool|int */ public function isConversationExists($userId) { if (empty($userId)) { return false; } $user = $this->getSerializeUser($this->authUserId, $userId); return $this->conversation->isExistsAmongTwoUsers($user['one'], $user['two']); }