From c04964e9407828d0909ba1f421012134af37145f Mon Sep 17 00:00:00 2001 From: Pierre Krieger Date: Tue, 12 Jan 2021 09:23:21 +0100 Subject: [PATCH] Update onion_addr.rs --- misc/multiaddr/src/onion_addr.rs | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/misc/multiaddr/src/onion_addr.rs b/misc/multiaddr/src/onion_addr.rs index 5df58bc6d19..29261287749 100644 --- a/misc/multiaddr/src/onion_addr.rs +++ b/misc/multiaddr/src/onion_addr.rs @@ -1,7 +1,4 @@ -use std::borrow::Cow; -use std::fmt::Debug; -use serde::export::Formatter; -use std::fmt; +use std::{borrow::Cow, fmt}; /// Represents an Onion v3 address #[derive(Clone)] @@ -44,8 +41,8 @@ impl<'a> From<(&'a [u8; 35], u16)> for Onion3Addr<'a> { } } -impl Debug for Onion3Addr<'_> { - fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), fmt::Error> { +impl fmt::Debug for Onion3Addr<'_> { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> Result<(), fmt::Error> { f.debug_tuple("Onion3Addr") .field(&format!("{:02x?}", &self.0[..])) .field(&self.1)