From eb87369a49153df256dba724b2b5e8ee40003ff1 Mon Sep 17 00:00:00 2001 From: nathan Date: Fri, 8 May 2026 10:12:25 -0700 Subject: [PATCH] Honor mining peer requirement in block templates --- src/rpc/mining.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rpc/mining.cpp b/src/rpc/mining.cpp index 9ac45837..a9c9a36a 100644 --- a/src/rpc/mining.cpp +++ b/src/rpc/mining.cpp @@ -460,7 +460,7 @@ UniValue getblocktemplate(const UniValue& params, bool fHelp) if (strMode != "template") throw JSONRPCError(RPC_INVALID_PARAMETER, "Invalid mode"); - if (vNodes.empty()) + if (vNodes.empty() && Params().MiningRequiresPeers()) throw JSONRPCError(RPC_CLIENT_NOT_CONNECTED, "Agrarian is not connected!"); if (IsInitialBlockDownload())