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