From f800613a0f77fa6ddf78b13510ef8b27b3d8184f Mon Sep 17 00:00:00 2001 From: Ardis Lu Date: Wed, 9 Aug 2023 20:57:19 -0700 Subject: [PATCH] Re-enable button on failure --- index.html | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/index.html b/index.html index f525c61..09d6f8c 100644 --- a/index.html +++ b/index.html @@ -212,11 +212,15 @@ bytecode = await fetchBytecode(address, rpc); if (bytecode === undefined) { // RPC call succeeded, but address has no bytecode logOutput(result, '❌ Smart contract address has no runtime bytecode.', address); + button.disabled = false; + spinner.style.setProperty('visibility', 'hidden'); return; } } catch { // RPC call failed logOutput(result, '❌ Failed to connect to JSON-RPC node.', rpc); + button.disabled = false; + spinner.style.setProperty('visibility', 'hidden'); return; } logOutput(result, '✅ Successfully fetched runtime bytecode.', bytecode); -- 2.47.3