WebSocket client bug fix