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

Function plugin_single_notify

lightningd/plugin.c:2460–2475  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2458}
2459
2460bool plugin_single_notify(struct plugin *p,
2461 const struct jsonrpc_notification *n TAKES)
2462{
2463 bool interested;
2464
2465 if (p->plugin_state == INIT_COMPLETE
2466 && plugin_subscriptions_contains(p, n->method)) {
2467 plugin_send(p, json_stream_dup(p, n->stream, p->log));
2468 interested = true;
2469 } else
2470 interested = false;
2471
2472 tal_free_if_taken(n);
2473
2474 return interested;
2475}
2476
2477void plugins_notify(struct plugins *plugins,
2478 const struct jsonrpc_notification *n TAKES)

Callers 2

notify_plugin_shutdownFunction · 0.85

Calls 4

plugin_sendFunction · 0.85
json_stream_dupFunction · 0.85
tal_free_if_takenFunction · 0.85

Tested by

no test coverage detected