Compare commits

..

2 Commits
0.7.3 ... 0.7.4

Author SHA1 Message Date
Guillermo Rauch
af2d9f285b Release 0.7.4 2011-06-30 12:48:00 -03:00
Guillermo Rauch
40c1f8da2b Fixed; only clear handlers if they were set. [level09] 2011-06-30 12:47:02 -03:00
5 changed files with 18 additions and 13 deletions

View File

@@ -1,4 +1,9 @@
0.7.4 / 2011-06-30
==================
* Fixed; only clear handlers if they were set. [level09]
0.7.3 / 2011-06-30
==================

View File

@@ -62,11 +62,7 @@ var io = sio.listen(app)
, nicknames = {};
io.set('transports', [
'websocket'
, 'flashsocket'
, 'htmlfile'
, 'xhr-polling'
, 'jsonp-polling'
]);
io.sockets.on('connection', function (socket) {

View File

@@ -15,7 +15,7 @@ var client = require('socket.io-client');
* Version.
*/
exports.version = '0.7.3';
exports.version = '0.7.4';
/**
* Supported protocol version.

View File

@@ -115,6 +115,8 @@ Transport.prototype.setHandlers = function () {
this.socket.on('close', this.bound.close);
this.socket.on('error', this.bound.error);
this.socket.on('drain', this.bound.drain);
this.handlersSet = true;
};
/**
@@ -124,14 +126,16 @@ Transport.prototype.setHandlers = function () {
*/
Transport.prototype.clearHandlers = function () {
this.store.unsubscribe('disconnect-force:' + this.id);
this.store.unsubscribe('heartbeat-clear:' + this.id);
this.store.unsubscribe('dispatch:' + this.id);
if (this.handlersSet) {
this.store.unsubscribe('disconnect-force:' + this.id);
this.store.unsubscribe('heartbeat-clear:' + this.id);
this.store.unsubscribe('dispatch:' + this.id);
this.socket.removeListener('end', this.bound.end);
this.socket.removeListener('close', this.bound.close);
this.socket.removeListener('error', this.bound.error);
this.socket.removeListener('drain', this.bound.drain);
this.socket.removeListener('end', this.bound.end);
this.socket.removeListener('close', this.bound.close);
this.socket.removeListener('error', this.bound.error);
this.socket.removeListener('drain', this.bound.drain);
}
};
/**

View File

@@ -1,6 +1,6 @@
{
"name": "socket.io"
, "version": "0.7.3"
, "version": "0.7.4"
, "description": "Realtime apps made cross-browser & easy with a WebSocket-like API"
, "homepage": "http://socket.io"
, "keywords": ["websocket", "socket", "realtime", "socket.io", "comet", "ajax"]