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

Function notify_sendpay_failure

lightningd/notification.c:423–442  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

421 sendpay_failure_notification_serialize);
422
423void notify_sendpay_failure(struct lightningd *ld,
424 const struct wallet_payment *payment,
425 enum jsonrpc_errcode pay_errcode,
426 const struct onionreply *onionreply,
427 const struct routing_failure *fail,
428 const char *errmsg)
429{
430 void (*serialize)(struct json_stream *,
431 const struct wallet_payment *,
432 enum jsonrpc_errcode,
433 const struct onionreply *,
434 const struct routing_failure *,
435 const char *) = sendpay_failure_notification_gen.serialize;
436
437 struct jsonrpc_notification *n =
438 jsonrpc_notification_start(NULL, "sendpay_failure");
439 serialize(n->stream, payment, pay_errcode, onionreply, fail, errmsg);
440 jsonrpc_notification_end(n);
441 plugins_notify(ld->plugins, take(n));
442}
443
444static void json_mvt_id(struct json_stream *stream, enum mvt_type mvt_type,
445 struct mvt_id *id)

Callers 1

tell_waiters_failedFunction · 0.70

Calls 3

jsonrpc_notification_endFunction · 0.85
plugins_notifyFunction · 0.85

Tested by

no test coverage detected