Skip to content

Commit 1cd4c90

Browse files
committed
fix: only log public IP from localpeer
1 parent 55febbe commit 1cd4c90

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

stackslib/src/net/db.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -96,10 +96,10 @@ pub struct LocalPeer {
9696

9797
impl fmt::Display for LocalPeer {
9898
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
99-
write!(f, "local::{}", self.port)?;
99+
write!(f, "local")?;
100100
match &self.public_ip_address {
101-
None => Ok(()),
102-
Some((addr, port)) => write!(f, "::pub={}", addr.to_socketaddr(*port)),
101+
None => write!(f, "::UNKNOWN"),
102+
Some((addr, port)) => write!(f, "::{}", addr.to_socketaddr(*port)),
103103
}
104104
}
105105
}

0 commit comments

Comments
 (0)