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

Function cleanup

plugins/xpay/xpay.c:341–353  ·  view source on GitHub ↗

Last of all we destroy the private layer */

Source from the content-addressed store, hash-verified

339
340/* Last of all we destroy the private layer */
341static struct command_result *cleanup(struct command *aux_cmd,
342 struct payment *payment)
343{
344 struct out_req *req;
345
346 req = jsonrpc_request_start(aux_cmd,
347 "askrene-remove-layer",
348 cleanup_finished,
349 cleanup_finished,
350 payment);
351 json_add_string(req->js, "layer", payment->private_layer);
352 return send_outreq(req);
353}
354
355/* Last request finished after xpay command is done gets to clean up */
356static void destroy_payment_request(struct out_req *req,

Callers 2

destroy_payment_requestFunction · 0.85
payment_give_upFunction · 0.85

Calls 2

json_add_stringFunction · 0.50
send_outreqFunction · 0.50

Tested by

no test coverage detected