Change Amount Debug impl to BTC with 8 decimals

This commit is contained in:
Steven Roose 2020-03-07 19:51:36 +00:00
parent 9cff794a09
commit 6186ee6269
No known key found for this signature in database
GPG Key ID: 2F2A88D7F8D68E87
1 changed files with 2 additions and 2 deletions

View File

@ -463,7 +463,7 @@ impl Ord for Amount {
impl fmt::Debug for Amount { impl fmt::Debug for Amount {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
write!(f, "Amount({} satoshi)", self.as_sat()) write!(f, "Amount({:.8} BTC)", self.as_btc())
} }
} }
@ -807,7 +807,7 @@ impl Ord for SignedAmount {
impl fmt::Debug for SignedAmount { impl fmt::Debug for SignedAmount {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
write!(f, "SignedAmount({} satoshi)", self.as_sat()) write!(f, "SignedAmount({:.8} BTC)", self.as_btc())
} }
} }