cleaned up sendDataToClients