When a user disconnects from the server, how can I find out the session ID?
At the moment I’ve got an ugly method of asking all existing clients to send a message back.
e.g. on the server:
socket.on('disconnect', function() {
// What’s the sessionid?
});
will give you the ID of the socket which was closed, but this is probably more of a hack… 🙂