| 488 | } |
| 489 | |
| 490 | static void add_sendpays_del_fields(struct out_req *req, |
| 491 | const char *buf, |
| 492 | const jsmntok_t *t) |
| 493 | { |
| 494 | const jsmntok_t *phash = json_get_member(buf, t, "payment_hash"); |
| 495 | const jsmntok_t *groupid = json_get_member(buf, t, "groupid"); |
| 496 | const jsmntok_t *partidtok = json_get_member(buf, t, "partid"); |
| 497 | const jsmntok_t *status = json_get_member(buf, t, "status"); |
| 498 | u64 partid; |
| 499 | |
| 500 | if (partidtok) |
| 501 | json_to_u64(buf, partidtok, &partid); |
| 502 | else |
| 503 | partid = 0; |
| 504 | |
| 505 | json_add_tok(req->js, "payment_hash", phash, buf); |
| 506 | json_add_tok(req->js, "status", status, buf); |
| 507 | json_add_tok(req->js, "groupid", groupid, buf); |
| 508 | json_add_u64(req->js, "partid", partid); |
| 509 | } |
| 510 | |
| 511 | static void add_forward_del_fields(struct out_req *req, |
| 512 | const char *buf, |
nothing calls this directly
no test coverage detected