Yes, you are right. I fixed this and also stated "and release any underlying resources associated with this socket" for every situation when `mySocket.readyState` is set to "closed".