Skip to content

Commit 1653e65

Browse files
committed
fix: cargo fmt
1 parent 8429e8c commit 1653e65

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

libp2p/src/tutorials/ping.rs

+9-3
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,9 @@
232232
//! yamux::Config::default,
233233
//! )?
234234
//! .with_behaviour(|_| ping::Behaviour::default())?
235-
//! .with_swarm_config(|cfg| cfg.with_idle_connection_timeout(Duration::from_secs(u64::MAX))) // Allows us to observe pings indefinitely.
235+
//! .with_swarm_config(|cfg| {
236+
//! cfg.with_idle_connection_timeout(Duration::from_secs(u64::MAX))
237+
//! }) // Allows us to observe pings indefinitely.
236238
//! .build();
237239
//!
238240
//! Ok(())
@@ -285,7 +287,9 @@
285287
//! yamux::Config::default,
286288
//! )?
287289
//! .with_behaviour(|_| ping::Behaviour::default())?
288-
//! .with_swarm_config(|cfg| cfg.with_idle_connection_timeout(Duration::from_secs(u64::MAX))) // Allows us to observe pings indefinitely.
290+
//! .with_swarm_config(|cfg| {
291+
//! cfg.with_idle_connection_timeout(Duration::from_secs(u64::MAX))
292+
//! }) // Allows us to observe pings indefinitely.
289293
//! .build();
290294
//!
291295
//! // Tell the swarm to listen on all interfaces and a random, OS-assigned
@@ -331,7 +335,9 @@
331335
//! yamux::Config::default,
332336
//! )?
333337
//! .with_behaviour(|_| ping::Behaviour::default())?
334-
//! .with_swarm_config(|cfg| cfg.with_idle_connection_timeout(Duration::from_secs(u64::MAX))) // Allows us to observe pings indefinitely.
338+
//! .with_swarm_config(|cfg| {
339+
//! cfg.with_idle_connection_timeout(Duration::from_secs(u64::MAX))
340+
//! }) // Allows us to observe pings indefinitely.
335341
//! .build();
336342
//!
337343
//! // Tell the swarm to listen on all interfaces and a random, OS-assigned

0 commit comments

Comments
 (0)