fixed bug where delegate didn't get nilled for the websocket