memory leak fix in closing of the scokets
[fix minor] Prevent crashes from attempting to remove listeners more than once when proxying websocket requests.