No. You don't need to check if the socket is open since you're inside the on sockopen event (which, surprisingly, triggers when a socket opens).