added force send update when server comes back
This commit is contained in:
@@ -77,7 +77,7 @@ function Node()
|
||||
if(self.changed())
|
||||
{
|
||||
self._socket = true;
|
||||
self.sendUpdate();
|
||||
self.sendUpdate(true);
|
||||
}
|
||||
|
||||
console.log('The connection has been established.');
|
||||
@@ -268,9 +268,9 @@ Node.prototype.prepareStats = function()
|
||||
};
|
||||
}
|
||||
|
||||
Node.prototype.sendUpdate = function()
|
||||
Node.prototype.sendUpdate = function(force)
|
||||
{
|
||||
if(this.changed())
|
||||
if(this.changed() || force)
|
||||
this.emit('update', this.prepareStats());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user