bitcoin-dot-org / developer.bitcoin.org

Bitcoin.org Developer Documentation
https://developer.bitcoin.org/
Other
183 stars 138 forks source link

Change terminology in getbestblockhash #109

Closed brunoerg closed 3 years ago

brunoerg commented 3 years ago

RPC code:


static RPCHelpMan getbestblockhash()
{
    return RPCHelpMan{"getbestblockhash",
                "\nReturns the hash of the best (tip) block in the most-work fully-validated chain.\n",
                {},
                RPCResult{
                    RPCResult::Type::STR_HEX, "", "the block hash, hex-encoded"},
                RPCExamples{
                    HelpExampleCli("getbestblockhash", "")
            + HelpExampleRpc("getbestblockhash", "")
                },
        [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue
{
    LOCK(cs_main);
    return ::ChainActive().Tip()->GetBlockHash().GetHex();
},
    };
}