[bisq-network/bisq] Provide more offer & contract detail to CLI (#5357)

Stan notifications at github.com
Fri Apr 2 17:59:53 CEST 2021


@ghubstan commented on this pull request.



> @@ -181,4 +190,32 @@ private static String formatTradeData(String format,
             t.getOffer().getBaseCurrencyCode().equals("BTC")
                     ? formatOfferVolume(t.getOffer().getVolume())
                     : formatSatoshis(t.getTradeAmountAsLong());
+
+    private static final BiFunction<TradeInfo, Boolean, String> bsqReceiveAddress = (t, showBsqBuyerAddress) -> {
+        if (showBsqBuyerAddress) {
+            ContractInfo contract = t.getContract();
+            boolean isBuyerMakerAndSellerTaker = contract.getIsBuyerMakerAndSellerTaker();
+            return isBuyerMakerAndSellerTaker  // (is BTC buyer / maker)
+                    ? contract.getTakerPaymentAccountPayload().getAddress()
+                    : contract.getMakerPaymentAccountPayload().getAddress();
+        } else {
+            return "";
+        }
+    };
+
+    private static boolean shouldShowBqsBuyerAddress(TradeInfo tradeInfo, boolean isTaker) {

Fixed in commit bddc273bb27ba73f93ed9e9cea4defa598c9f28c.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/bisq-network/bisq/pull/5357#discussion_r606301166
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bisq.network/pipermail/bisq-github/attachments/20210402/785a6ade/attachment.htm>


More information about the bisq-github mailing list