chore: refactor boot_nodes usage to eliminate redundancy (#15258)

Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de>
This commit is contained in:
Frag
2025-03-26 16:25:50 +02:00
committed by GitHub
parent b0d55f665c
commit d41e38f315

View File

@@ -51,8 +51,10 @@ async fn main() {
let secret_key = SecretKey::new(&mut rand::thread_rng());
let bsc_boot_nodes = boot_nodes();
let net_cfg = NetworkConfig::builder(secret_key)
.boot_nodes(boot_nodes())
.boot_nodes(bsc_boot_nodes.clone())
.set_head(head())
.with_pow()
.listener_addr(local_addr)
@@ -61,7 +63,7 @@ async fn main() {
let net_cfg = net_cfg.set_discovery_v4(
Discv4ConfigBuilder::default()
.add_boot_nodes(boot_nodes())
.add_boot_nodes(bsc_boot_nodes)
.lookup_interval(Duration::from_millis(500))
.build(),
);