From 4a41ba6a995697c6642d0d5764b8075abd7bda4a Mon Sep 17 00:00:00 2001 From: Overtorment Date: Thu, 3 Dec 2020 16:31:31 +0000 Subject: [PATCH] FIX: fetch wallet transaction after broadcast --- screen/send/confirm.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/screen/send/confirm.js b/screen/send/confirm.js index e7404ddcf..8befb15c8 100644 --- a/screen/send/confirm.js +++ b/screen/send/confirm.js @@ -91,14 +91,15 @@ export default class Confirm extends Component { amount = formatBalanceWithoutSuffix(amount, BitcoinUnit.BTC, false); - this.context.fetchAndSaveWalletTransactions(this.state.fromWallet.getID()); this.props.navigation.navigate('Success', { fee: Number(this.state.fee), amount, - dismissModal: () => this.props.navigation.dangerouslyGetParent().pop(), }); this.setState({ isLoading: false }); + + await new Promise(resolve => setTimeout(resolve, 3000)); // sleep to make sure network propagates + this.context.fetchAndSaveWalletTransactions(this.state.fromWallet.getID()); } catch (error) { ReactNativeHapticFeedback.trigger('notificationError', { ignoreAndroidSystemSettings: false,