Bug fix with socket.io client