Show trade.price in margin based altcoin 'gettrade' console output

Fixes problem simlar to other CLI output changes in this PR.
CLI's 'gettrade' output should show contracted trade.price instead of
moving offer.price value for price margin based altcoin offers.

This fixed bug did not affect any fiat or BSQ trades, only price margin
based XMR trades, and API support for XMR trading has not yet been
released.
This commit is contained in:
ghubstan 2021-09-18 13:40:55 -03:00
parent 542aa774b0
commit 55cb126e4f
No known key found for this signature in database
GPG Key ID: E35592D6800A861E

View File

@ -159,7 +159,7 @@ public class TradeFormat {
private static final Function<TradeInfo, String> priceFormat = (t) ->
t.getOffer().getBaseCurrencyCode().equals("BTC")
? formatPrice(t.getTradePrice())
: formatCryptoCurrencyPrice(t.getOffer().getPrice());
: formatCryptoCurrencyPrice(t.getTradePrice());
private static final Function<TradeInfo, String> amountFormat = (t) ->
t.getOffer().getBaseCurrencyCode().equals("BTC")