From ffac1a33d70a424b5703c14f0a8c73d8ce28cc76 Mon Sep 17 00:00:00 2001 From: Deirdre Connolly Date: Thu, 26 Mar 2020 21:34:35 -0400 Subject: [PATCH] Impl Debug for PayingKey --- zebra-chain/src/keys/sprout.rs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/zebra-chain/src/keys/sprout.rs b/zebra-chain/src/keys/sprout.rs index 3df5626f..4a658996 100644 --- a/zebra-chain/src/keys/sprout.rs +++ b/zebra-chain/src/keys/sprout.rs @@ -51,9 +51,17 @@ impl From for ReceivingKey { } /// Derived from a _SpendingKey_. -#[derive(Copy, Clone, Debug, Eq, PartialEq)] +#[derive(Copy, Clone, Eq, PartialEq)] pub struct PayingKey(pub [u8; 32]); +impl fmt::Debug for PayingKey { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + f.debug_tuple("PayingKey") + .field(&hex::encode(&self.0)) + .finish() + } +} + impl From for PayingKey { /// For this invocation of SHA256Compress as the PRF, t=1. ///