MCPcopy Create free account
hub / github.com/ElementsProject/lightning / json_deprecations

Function json_deprecations

lightningd/jsonrpc.c:1709–1725  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1707AUTODATA(json_command, &batching_command);
1708
1709static struct command_result *json_deprecations(struct command *cmd,
1710 const char *buffer,
1711 const jsmntok_t *obj UNNEEDED,
1712 const jsmntok_t *params)
1713{
1714 bool *enable;
1715
1716 if (!param(cmd, buffer, params,
1717 p_req("enable", param_bool, &enable),
1718 NULL))
1719 return command_param_failed();
1720
1721 /* Catch the case where they sent this command then hung up. */
1722 if (cmd->jcon)
1723 cmd->jcon->deprecated_ok = *enable;
1724 return command_success(cmd, json_stream_success(cmd));
1725}
1726
1727static const struct json_command deprecations_command = {
1728 "deprecations",

Callers

nothing calls this directly

Calls 4

command_param_failedFunction · 0.70
command_successFunction · 0.70
json_stream_successFunction · 0.70
paramFunction · 0.50

Tested by

no test coverage detected