I have the following method:
Meteor.onConnection(function (connection) {
console.log("New DDP Connection:", connection.id);
connection.onClose(function() {
console.log("DDP Disconnect:", connection.id);
});
});
But how do I know whether a connection is disconnected by the server or the client?