Ejemplo n.º 1
0
        public async Task SendGroupMessage(LivechatMessagePack messagePack)
        {
            if (messagePack.FromConnectionId == null)
            {
                messagePack.FromConnectionId = hubContext.ConnectionId;
            }

            if (messagePack.IsPersistent)
            {
                await messageLogger.CreateLog(messagePack);
            }

            await clientsManager
            .Group(messagePack.ChannelId)
            .SendAsync(HubMessages.SEND, messagePack);
        }