From a642ecb6f594e9a1253def84481ad07c43840688 Mon Sep 17 00:00:00 2001 From: koalasat Date: Mon, 16 Sep 2024 15:28:39 +0200 Subject: [PATCH] Fix trade summary sats --- frontend/src/components/OrderDetails/index.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/components/OrderDetails/index.tsx b/frontend/src/components/OrderDetails/index.tsx index a368df36..19a9e674 100644 --- a/frontend/src/components/OrderDetails/index.tsx +++ b/frontend/src/components/OrderDetails/index.tsx @@ -181,7 +181,7 @@ const OrderDetails = ({ const rate = Number(order.max_amount ?? order.amount) / btc_now; if (isBuyer) { - if (order.amount > 0) { + if (order.amount && order.amount > 0) { sats = computeSats({ amount: order.amount, fee: -tradeFee, @@ -211,7 +211,7 @@ const OrderDetails = ({ amount: sats, }); } else { - if (order.amount > 0) { + if (order.amount && order.amount > 0) { sats = computeSats({ amount: order.amount, fee: tradeFee,