Skip to content

Commit

Permalink
small refactor with then_some (#1533)
Browse files Browse the repository at this point in the history
small refactor with then_some
  • Loading branch information
tcoratger authored Oct 20, 2024
1 parent aa0ef94 commit ffc9921
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crates/node-bindings/src/nodes/reth.rs
Original file line number Diff line number Diff line change
Expand Up @@ -517,7 +517,7 @@ impl Reth {
instance: self.instance,
http_port,
ws_port,
p2p_port: if p2p_port != 0 { Some(p2p_port) } else { None },
p2p_port: (p2p_port != 0).then_some(p2p_port),
ipc: self.ipc_path,
data_dir: self.data_dir,
auth_port: Some(auth_port),
Expand Down

0 comments on commit ffc9921

Please sign in to comment.