fixed buggy if

This commit is contained in:
cubedro 2016-12-11 22:29:03 +02:00
parent 1c1cb25d63
commit 941c17a201
1 changed files with 1 additions and 1 deletions

View File

@ -169,7 +169,7 @@ History.prototype.add = function(block, id, trusted, addingHistory)
propagTimes: []
}
if( this._items.length === 0 || (this._items.length === MAX_HISTORY && block.number > this.worstBlockNumber() && !addingHistory) || (this._items.length < MAX_HISTORY && block.number < this.bestBlockNumber()) )
if( this._items.length === 0 || (this._items.length === MAX_HISTORY && block.number > this.worstBlockNumber()) || (this._items.length < MAX_HISTORY && block.number < this.bestBlockNumber() && addingHistory) )
{
item.propagTimes.push({
node: id,