Check if the provider supportsFixedRate only if fixed rate is applied [skip ci]

This commit is contained in:
OmarHatem 2022-12-07 18:15:30 +02:00
parent a9f0466825
commit 8ff8cf38b8

View file

@ -310,7 +310,7 @@ abstract class ExchangeViewModelBase with Store {
final result = await Future.wait<double>(
_tradeAvailableProviders
.where((element) => element.supportsFixedRate)
.where((element) => !isFixedRateMode || element.supportsFixedRate)
.map((element) => element.calculateAmount(
from: depositCurrency,
to: receiveCurrency,