Updated client

heartbitTimeout > heartbeatTimeout
This commit is contained in:
Guillermo Rauch
2010-07-28 21:25:10 -07:00
parent 0a2d007179
commit f87d883d79
2 changed files with 3 additions and 3 deletions

View File

@@ -111,7 +111,7 @@ Client.prototype._heartbeat = function(){
var self = this;
setTimeout(function(){
self.send('~h~' + ++self._heartbeats);
self._heartbitTimeout = setTimeout(function(){
self._heartbeatTimeout = setTimeout(function(){
self._onClose();
}, self.options.timeout);
}, self.options.heartbeatInterval);
@@ -119,7 +119,7 @@ Client.prototype._heartbeat = function(){
Client.prototype._onHeartbeat = function(h){
if (h == this._heartbeats){
clearTimeout(this._heartbitTimeout);
clearTimeout(this._heartbeatTimeout);
this._heartbeat();
}
};