diff --git a/src/provider.cpp b/src/provider.cpp index 79f651a..1d7e229 100644 --- a/src/provider.cpp +++ b/src/provider.cpp @@ -735,7 +735,7 @@ std::string Provider::getContractDeployedInLatestBlock() { throw std::runtime_error("Failed to get the latest block"); nlohmann::json blockJson = *result; - for (const auto& tx : blockJson["result"]["transactions"]) { + for (const auto& tx : blockJson["transactions"]) { std::optional transactionReceipt = getTransactionReceipt(tx["hash"].get()); if (transactionReceipt.has_value()) return transactionReceipt->at("contractAddress").get();