Move monero serde code to lib

This commit is contained in:
Tobin C. Harding 2020-10-22 13:54:13 +11:00
parent 30298bdf1f
commit eed5e8e9a4
3 changed files with 29 additions and 36 deletions

View file

@ -4,7 +4,6 @@ use std::fmt::{self, Display};
pub mod alice;
pub mod bitcoin;
pub mod bob;
pub mod monero;
pub mod network;
pub const ONE_BTC: u64 = 100_000_000;
@ -34,7 +33,7 @@ pub struct SwapAmounts {
#[serde(with = "::bitcoin::util::amount::serde::as_sat")]
pub btc: ::bitcoin::Amount,
/// Amount of XMR to swap.
#[serde(with = "crate::monero::amount_serde")]
#[serde(with = "xmr_btc::serde::monero_amount")]
pub xmr: xmr_btc::monero::Amount,
}