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

Function notify_forward_event

lightningd/notification.c:346–369  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

344 forward_event_notification_serialize);
345
346void notify_forward_event(struct lightningd *ld,
347 const struct htlc_in *in,
348 const struct short_channel_id *scid_out,
349 const struct amount_msat *amount_out,
350 enum forward_status state,
351 enum onion_wire failcode,
352 struct timeabs *resolved_time,
353 enum forward_style forward_style)
354{
355 void (*serialize)(struct json_stream *,
356 const struct htlc_in *,
357 const struct short_channel_id *,
358 const struct amount_msat *,
359 enum forward_status,
360 enum onion_wire,
361 struct timeabs *,
362 enum forward_style) = forward_event_notification_gen.serialize;
363
364 struct jsonrpc_notification *n
365 = jsonrpc_notification_start(NULL, forward_event_notification_gen.topic);
366 serialize(n->stream, in, scid_out, amount_out, state, failcode, resolved_time, forward_style);
367 jsonrpc_notification_end(n);
368 plugins_notify(ld->plugins, take(n));
369}
370
371static void sendpay_success_notification_serialize(struct json_stream *stream,
372 const struct wallet_payment *payment)

Callers

nothing calls this directly

Calls 3

jsonrpc_notification_endFunction · 0.85
plugins_notifyFunction · 0.85

Tested by

no test coverage detected