From 888b004c208426dd3b8fc64131354696b2dbb920 Mon Sep 17 00:00:00 2001 From: jinoosss Date: Tue, 19 Nov 2024 14:51:33 +0900 Subject: [PATCH] fix: prevent loading when the network fails --- packages/adena-extension/src/router/popup/loading-main.tsx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/adena-extension/src/router/popup/loading-main.tsx b/packages/adena-extension/src/router/popup/loading-main.tsx index 46630560..76c27b20 100644 --- a/packages/adena-extension/src/router/popup/loading-main.tsx +++ b/packages/adena-extension/src/router/popup/loading-main.tsx @@ -59,15 +59,16 @@ const LoadingMain = (): ReactElement => { if (state === 'CREATE' || state === 'LOGIN') { return false; } - if (isLoadingImage) { - return true; - } if (state === 'FINISH') { // If `failedNetwork` is null, it is loading. if (failedNetwork) { return false; } if (failedNetwork === false) { + if (isLoadingImage) { + return true; + } + if (currentBalances.length > 0) { return false; }