Added bug fixes for WebSocket RPC.