try to choose from at least 5 potential peers when syncing.

This commit is contained in:
Christopher Jeffrey 2015-12-18 16:52:32 -08:00
parent 086b32cb73
commit e735249d0d

View File

@ -430,7 +430,7 @@ Pool.prototype._addPeer = function _addPeer(backoff) {
peer.on('ack', function() {
if (self.options.fullNode) {
if (self.peers.block.length >= self.size)
if (self.peers.block.length >= Math.min(5, self.size))
self.startSync();
}
});