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

Function json_batching

lightningd/jsonrpc.c:1685–1701  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1683AUTODATA(json_command, &notifications_command);
1684
1685static struct command_result *json_batching(struct command *cmd,
1686 const char *buffer,
1687 const jsmntok_t *obj UNNEEDED,
1688 const jsmntok_t *params)
1689{
1690 bool *enable;
1691
1692 if (!param(cmd, buffer, params,
1693 p_req("enable", param_bool, &enable),
1694 NULL))
1695 return command_param_failed();
1696
1697 /* Catch the case where they sent this command then hung up. */
1698 if (cmd->jcon)
1699 cmd->jcon->db_batching = *enable;
1700 return command_success(cmd, json_stream_success(cmd));
1701}
1702
1703static const struct json_command batching_command = {
1704 "batching",

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