From e0b9ecdbcbf33abbc5f767a035822c9cfc1706f5 Mon Sep 17 00:00:00 2001 From: Christian Decker Date: Wed, 4 Mar 2020 19:41:15 +0100 Subject: [PATCH] fixup! lightningd/jsonrpc: Add a 'rpc_command' hook --- lightningd/jsonrpc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lightningd/jsonrpc.c b/lightningd/jsonrpc.c index bf41f42c720b..7f5a35bf7821 100644 --- a/lightningd/jsonrpc.c +++ b/lightningd/jsonrpc.c @@ -617,7 +617,8 @@ static void rpc_command_hook_serialize(struct rpc_command_hook_payload *p, json_object_start(s, "rpc_command"); #ifdef COMPAT_V081 - json_add_tok(s, "rpc_command", p->request, p->buffer); + if (deprecated_apis) + json_add_tok(s, "rpc_command", p->request, p->buffer); #endif json_for_each_obj(i, tok, p->request) {