Skip to content

Commit

Permalink
Merge pull request socketio#1082 from shapeshed/master
Browse files Browse the repository at this point in the history
Fix leaking message:id, disconnect:id
  • Loading branch information
rauchg committed Nov 28, 2012
2 parents 373eadf + 6256f56 commit 80036cc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/manager.js
Original file line number Diff line number Diff line change
Expand Up @@ -510,15 +510,15 @@ Manager.prototype.onClientMessage = function (id, packet) {
* @api private
*/

Manager.prototype.onClientDisconnect = function (id, reason) {
Manager.prototype.onClientDisconnect = function (id, reason, local) {
for (var name in this.namespaces) {
if (this.namespaces.hasOwnProperty(name)) {
this.namespaces[name].handleDisconnect(id, reason, typeof this.roomClients[id] !== 'undefined' &&
typeof this.roomClients[id][name] !== 'undefined');
}
}

this.onDisconnect(id);
this.onDisconnect(id, local);
};

/**
Expand Down

0 comments on commit 80036cc

Please sign in to comment.