Skip to content

Commit

Permalink
fix blocktime null
Browse files Browse the repository at this point in the history
  • Loading branch information
willyfromtheblock committed Jun 21, 2021
1 parent 4ae4d46 commit 430304c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/providers/activewallets.dart
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ class ActiveWallets with ChangeNotifier {
if (isInWallet == true) {
if (walletTx.timestamp == 0) {
//did the tx confirm?
walletTx.newTimestamp = tx['blocktime'];
walletTx.newTimestamp = tx['blocktime'] ?? 0;
}
if (tx['confirmations'] != null &&
walletTx.confirmations < tx['confirmations']) {
Expand Down Expand Up @@ -347,7 +347,7 @@ class ActiveWallets with ChangeNotifier {

openWallet.putTransaction(WalletTransaction(
txid: tx['txid'],
timestamp: tx['blocktime'],
timestamp: tx['blocktime'] ?? 0,
value: tx['outValue'],
fee: tx['outFees'],
address: address,
Expand Down

0 comments on commit 430304c

Please sign in to comment.