mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-13 12:33:42 +02:00
combineblocksigs should check if signed blocks are active
This commit is contained in:
parent
52cfdca0f7
commit
3e785f2bcc
1 changed files with 4 additions and 0 deletions
|
|
@ -1005,6 +1005,10 @@ UniValue combineblocksigs(const JSONRPCRequest& request)
|
|||
+ HelpExampleCli("combineblocksigs", "<hex> [\"signature1\", \"signature2\", ...]")
|
||||
);
|
||||
|
||||
if (!g_signed_blocks) {
|
||||
throw JSONRPCError(RPC_MISC_ERROR, "Signed blocks are not active for this network.");
|
||||
}
|
||||
|
||||
CBlock block;
|
||||
if (!DecodeHexBlk(block, request.params[0].get_str()))
|
||||
throw JSONRPCError(RPC_DESERIALIZATION_ERROR, "Block decode failed");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue