mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-02 16:21:42 +00:00
Add peers to backfill if FullySynced
This commit is contained in:
@@ -416,7 +416,6 @@ impl<T: BeaconChainTypes> SyncManager<T> {
|
||||
PeerSyncType::Advanced => {
|
||||
self.range_sync
|
||||
.add_peer(&mut self.network, local, peer_id, remote);
|
||||
self.backfill_sync.add_peer(peer_id);
|
||||
}
|
||||
PeerSyncType::FullySynced => {
|
||||
// Sync considers this peer close enough to the head to not trigger range sync.
|
||||
@@ -434,6 +433,13 @@ impl<T: BeaconChainTypes> SyncManager<T> {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
match sync_type {
|
||||
PeerSyncType::Behind => {}
|
||||
PeerSyncType::Advanced | PeerSyncType::FullySynced => {
|
||||
self.backfill_sync.add_peer(peer_id);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
self.update_sync_state();
|
||||
|
||||
Reference in New Issue
Block a user