diff --git a/cw_bitcoin/lib/electrum_transaction_history.dart b/cw_bitcoin/lib/electrum_transaction_history.dart index 806f813dd..b688f097b 100644 --- a/cw_bitcoin/lib/electrum_transaction_history.dart +++ b/cw_bitcoin/lib/electrum_transaction_history.dart @@ -76,8 +76,13 @@ abstract class ElectrumTransactionHistoryBase final val = entry.value; if (val is Map) { - final tx = ElectrumTransactionInfo.fromJson(val, walletInfo.type); - _update(tx); + // removing transactions with invalid date + if (val['date'] == 1168650000) { + transactions.remove(entry.key); + } else { + final tx = ElectrumTransactionInfo.fromJson(val, walletInfo.type); + _update(tx); + } } }); diff --git a/cw_bitcoin/lib/electrum_wallet.dart b/cw_bitcoin/lib/electrum_wallet.dart index 191272b1f..fe8782adb 100644 --- a/cw_bitcoin/lib/electrum_wallet.dart +++ b/cw_bitcoin/lib/electrum_wallet.dart @@ -1613,7 +1613,7 @@ abstract class ElectrumWalletBase } if (height != null) { - if (time == null) { + if (time == null && height > 0) { time = (getDateByBitcoinHeight(height).millisecondsSinceEpoch / 1000).round(); }