mirror of
https://github.com/BlueWallet/BlueWallet.git
synced 2025-03-13 19:16:52 +01:00
parent
63a3c61534
commit
e3fcbbb713
1 changed files with 4 additions and 19 deletions
|
@ -369,12 +369,10 @@ const WalletDetails: React.FC = () => {
|
|||
if (wallet.type === HDSegwitBech32Wallet.type) {
|
||||
wallet._txs_by_external_index = {};
|
||||
wallet._txs_by_internal_index = {};
|
||||
presentAlert({ message: msg });
|
||||
|
||||
wallet._balances_by_external_index = {};
|
||||
wallet._balances_by_internal_index = {};
|
||||
wallet._utxo = [];
|
||||
if ('transactions' in wallet) {
|
||||
wallet.transactions = [];
|
||||
}
|
||||
wallet._lastTxFetch = 0;
|
||||
wallet._lastBalanceFetch = 0;
|
||||
}
|
||||
|
@ -385,30 +383,17 @@ const WalletDetails: React.FC = () => {
|
|||
wallet._hdWalletInstance._txs_by_external_index = {};
|
||||
// @ts-expect-error: Need to fix later
|
||||
wallet._hdWalletInstance._txs_by_internal_index = {};
|
||||
|
||||
// @ts-expect-error: Need to fix later
|
||||
wallet._hdWalletInstance._balances_by_external_index = {};
|
||||
// @ts-expect-error: Need to fix later
|
||||
wallet._hdWalletInstance._balances_by_internal_index = {};
|
||||
// @ts-expect-error: Need to fix later
|
||||
wallet._hdWalletInstance._utxo = [];
|
||||
// @ts-expect-error: Need to fix later
|
||||
if ('transactions' in wallet._hdWalletInstance) {
|
||||
// @ts-expect-error: Need to fix later
|
||||
wallet._hdWalletInstance.transactions = [];
|
||||
}
|
||||
// @ts-expect-error: Need to fix later
|
||||
wallet._hdWalletInstance._lastTxFetch = 0;
|
||||
// @ts-expect-error: Need to fix later
|
||||
wallet._hdWalletInstance._lastBalanceFetch = 0;
|
||||
presentAlert({ message: msg });
|
||||
}
|
||||
|
||||
// Save changes to disk
|
||||
await saveToDisk();
|
||||
presentAlert({ message: msg });
|
||||
|
||||
// Force refresh on UI
|
||||
setHideTransactionsInWalletsList(!hideTransactionsInWalletsList);
|
||||
setTimeout(() => setHideTransactionsInWalletsList(hideTransactionsInWalletsList), 500);
|
||||
};
|
||||
|
||||
const walletNameTextInputOnBlur = useCallback(async () => {
|
||||
|
|
Loading…
Add table
Reference in a new issue