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

Function json_add_config_plugin

lightningd/plugin.c:1557–1572  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1555}
1556
1557void json_add_config_plugin(struct json_stream *stream,
1558 const struct plugins *plugins,
1559 const char *fieldname,
1560 const struct opt_table *ot)
1561{
1562 struct plugin *plugin;
1563
1564 /* Shortcut */
1565 if (!is_plugin_opt(ot))
1566 return;
1567
1568 /* Find the plugin that registered this RPC call */
1569 plugin = plugin_opt_find_any(plugins, ot, NULL);
1570 if (plugin)
1571 json_add_string(stream, fieldname, plugin->cmd);
1572}
1573
1574/* Start command might have included plugin-specific parameters.
1575 * We make sure they *are* parameters for this plugin, then add them

Callers 1

json_add_configFunction · 0.85

Calls 3

is_plugin_optFunction · 0.85
plugin_opt_find_anyFunction · 0.85
json_add_stringFunction · 0.50

Tested by

no test coverage detected