Skip to content

Commit

Permalink
Change Amount Debug impl to BTC with 8 decimals
Browse files Browse the repository at this point in the history
  • Loading branch information
stevenroose committed Mar 7, 2020
1 parent 9cff794 commit 6186ee6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/util/amount.rs
Expand Up @@ -463,7 +463,7 @@ impl Ord for Amount {

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

Expand Down Expand Up @@ -807,7 +807,7 @@ impl Ord for SignedAmount {

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

Expand Down

0 comments on commit 6186ee6

Please sign in to comment.