Fix deviation percent for fixed-price crypto offers (#1411)
Some checks are pending
CI / build (macos-13) (push) Waiting to run
CI / build (ubuntu-22.04) (push) Waiting to run
CI / build (windows-latest) (push) Waiting to run
Codacy Coverage Reporter / Publish coverage (push) Waiting to run
CodeQL / Analyze (push) Waiting to run

This commit is contained in:
bvcxza 2024-11-14 12:16:13 -03:00 committed by GitHub
parent ea8badd3f6
commit 023e2bcd2f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -402,9 +402,7 @@ abstract class OfferBookViewModel extends ActivatableViewModel {
}
public Optional<Double> getMarketBasedPrice(Offer offer) {
OfferDirection displayDirection = offer.isTraditionalOffer() ? direction :
direction.equals(OfferDirection.BUY) ? OfferDirection.SELL : OfferDirection.BUY;
return priceUtil.getMarketBasedPrice(offer, displayDirection);
return priceUtil.getMarketBasedPrice(offer, direction);
}
String formatMarketPriceMarginPct(Offer offer) {