History length typo

This commit is contained in:
Gusto 2023-10-16 16:21:18 +03:00
parent b521375ad4
commit 884d837ab5
1 changed files with 2 additions and 2 deletions

View File

@ -34,7 +34,7 @@ impl Default for SwarmConfig {
#[serde(remote = "gossipsub::Config")] #[serde(remote = "gossipsub::Config")]
struct GossipsubConfigDef { struct GossipsubConfigDef {
#[serde(getter = "gossipsub::Config::history_length")] #[serde(getter = "gossipsub::Config::history_length")]
history_legnth: usize, history_length: usize,
#[serde(getter = "gossipsub::Config::history_gossip")] #[serde(getter = "gossipsub::Config::history_gossip")]
history_gossip: usize, history_gossip: usize,
#[serde(getter = "gossipsub::Config::mesh_n")] #[serde(getter = "gossipsub::Config::mesh_n")]
@ -103,7 +103,7 @@ impl From<GossipsubConfigDef> for gossipsub::Config {
fn from(def: GossipsubConfigDef) -> gossipsub::Config { fn from(def: GossipsubConfigDef) -> gossipsub::Config {
let mut builder = gossipsub::ConfigBuilder::default(); let mut builder = gossipsub::ConfigBuilder::default();
let mut builder = builder let mut builder = builder
.history_length(def.history_legnth) .history_length(def.history_length)
.history_gossip(def.history_gossip) .history_gossip(def.history_gossip)
.mesh_n(def.mesh_n) .mesh_n(def.mesh_n)
.mesh_n_low(def.mesh_n_low) .mesh_n_low(def.mesh_n_low)