update to work with ws instead of websocket-server