private void SendMessageToEachClient(GroupChat group, string message) { ChatUtils.SendMessageToEachClient(message, _data.AllGroupsChat.ClientConnectToGroup[group], _requests); List <TcpClient> allClientsNotConnected = GetAllUnConnectedClients(group); SaveAlerts(allClientsNotConnected, group); _data.AllGroupsChat.AddMessageToHistory(group, message); _logger.LogInformation($"Received in group {group.Name} and Sending all: {message}"); }
private void SendMessageToEachClient(string message) { ChatUtils.SendMessageToEachClient(message, _data.ClientsInGlobalChat.Clients.Values.ToList(), _requests); }