27 if (!Loader::includeModule(
'im'))
32 if (empty($recipientIds))
37 $skipChat = $parameters[
'skipChat'] ??
false;
45 foreach ($recipientIds as $recipientId)
47 if ($recipientId === $this->senderId)
49 $factory = ActionMessageFactory::getInstance();
50 $acceptMessage = $factory->getActionMessage(ActionType::AcceptUser, $this->collabId, $this->senderId);
52 $acceptMessage->send();
57 $recipientNames[] = $this->
getName($this->senderId, $recipientId, $this->collabId);
60 if (empty($recipientNames))
65 $userNames = implode(
', ', $recipientNames);
66 $senderName = $this->
getName($this->senderId, $this->senderId, $this->collabId);
69 $key =
'SOCIALNETWORK_COLLAB_CHAT_USER_ADD_GUEST' . $this->
getGenderSuffix($this->senderId);
75 '#SENDER_NAME#' => $senderName,
76 '#RECIPIENT#' => $userNames,