diff --git a/packages/nextjs/pages/index.tsx b/packages/nextjs/pages/index.tsx index 95c77b88..afc2a4aa 100644 --- a/packages/nextjs/pages/index.tsx +++ b/packages/nextjs/pages/index.tsx @@ -124,6 +124,11 @@ const Home: NextPage = () => { try { const response = await fetch(`https://heimdall-api.fly.dev/${network}/${contractAddress}`); const abi = await response.json(); + if (abi.length === 0) { + notification.error("Failed to fetch ABI from Heimdall. Please try again or enter ABI manually."); + setIsFetchingAbi(false); + return; + } setContractAbi(abi); setIsAbiAvailable(true); setAbiContractAddress(contractAddress);