Merge pull request #623 from cake-tech/fix-trade-datails-screen-for-SideShift

CW-255 SideShift confirm sending screen bug
This commit is contained in:
Omar Hatem 2022-12-06 17:30:05 +02:00 committed by GitHub
commit 50fd6accef
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -249,11 +249,12 @@ class SideShiftExchangeProvider extends ExchangeProvider {
final expectedSendAmount = responseJSON['depositAmount'].toString();
final deposits = responseJSON['deposits'] as List?;
TradeState? state;
String? status;
if (deposits != null && deposits.isNotEmpty) {
final status = deposits[0]['status'] as String;
state = TradeState.deserialize(raw: status);
if (deposits?.isNotEmpty ?? false) {
status = deposits![0]['status'] as String?;
}
state = TradeState.deserialize(raw: status ?? 'created');
final expiredAtRaw = responseJSON['expiresAtISO'] as String;
final expiredAt =