mirror of
https://github.com/BlueWallet/BlueWallet.git
synced 2025-03-13 19:16:52 +01:00
FIX: Carousel on the main screen does not working from the first go
This commit is contained in:
parent
d338f813cb
commit
f8629e2555
1 changed files with 4 additions and 3 deletions
|
@ -246,8 +246,10 @@ export const StorageProvider = ({ children }: { children: React.ReactNode }) =>
|
|||
console.debug('[refreshAllWalletTransactions] Refresh already in progress');
|
||||
return;
|
||||
}
|
||||
console.debug('[refreshAllWalletTransactions] Starting refreshAllWalletTransactions');
|
||||
refreshingRef.current = true;
|
||||
|
||||
await new Promise<void>(resolve => InteractionManager.runAfterInteractions(() => resolve()));
|
||||
|
||||
const TIMEOUT_DURATION = 30000;
|
||||
const timeoutPromise = new Promise<never>((_resolve, reject) =>
|
||||
setTimeout(() => {
|
||||
|
@ -292,12 +294,11 @@ export const StorageProvider = ({ children }: { children: React.ReactNode }) =>
|
|||
console.debug('[refreshAllWalletTransactions] Saving data to disk');
|
||||
await saveToDisk();
|
||||
})(),
|
||||
|
||||
timeoutPromise,
|
||||
]);
|
||||
console.debug('[refreshAllWalletTransactions] Refresh completed successfully');
|
||||
} catch (error) {
|
||||
console.error('[refreshAllWalletTransactions] Error in refreshAllWalletTransactions:', error);
|
||||
console.error('[refreshAllWalletTransactions] Error:', error);
|
||||
} finally {
|
||||
console.debug('[refreshAllWalletTransactions] Resetting wallet transaction status and refresh lock');
|
||||
setWalletTransactionUpdateStatus(WalletTransactionsStatus.NONE);
|
||||
|
|
Loading…
Add table
Reference in a new issue