diff --git a/src/cli/take_buy.rs b/src/cli/take_buy.rs index fbce44a..9dffe15 100644 --- a/src/cli/take_buy.rs +++ b/src/cli/take_buy.rs @@ -26,7 +26,7 @@ pub async fn execute_take_buy( Some(*order_id), Some(master_pubkey), Action::TakeBuy, - Some(Content::PaymentRequest(None, String::new(), amount)), + amount.map(Content::Amount), ) .as_json() .unwrap(); diff --git a/src/cli/take_sell.rs b/src/cli/take_sell.rs index 3e958f5..06e247b 100644 --- a/src/cli/take_sell.rs +++ b/src/cli/take_sell.rs @@ -39,7 +39,7 @@ pub async fn execute_take_sell( if amount.is_some() { content = match content { Some(Content::PaymentRequest(a, b, _)) => Some(Content::PaymentRequest(a, b, amount)), - None => Some(Content::PaymentRequest(None, String::new(), amount)), + None => Some(Content::Amount(amount.unwrap())), _ => None, }; }