Change functionality to handle multiple websocket groups