| 4533 | } |
| 4534 | |
| 4535 | struct db_stmt *payments_by_hash(struct wallet *wallet, |
| 4536 | const struct sha256 *payment_hash) |
| 4537 | { |
| 4538 | struct db_stmt *stmt; |
| 4539 | stmt = db_prepare_v2(wallet->db, SQL("SELECT" |
| 4540 | " id" |
| 4541 | ", updated_index" |
| 4542 | ", status" |
| 4543 | ", destination" |
| 4544 | ", msatoshi" |
| 4545 | ", payment_hash" |
| 4546 | ", timestamp" |
| 4547 | ", payment_preimage" |
| 4548 | ", path_secrets" |
| 4549 | ", route_nodes" |
| 4550 | ", route_channels" |
| 4551 | ", msatoshi_sent" |
| 4552 | ", description" |
| 4553 | ", bolt11" |
| 4554 | ", paydescription" |
| 4555 | ", failonionreply" |
| 4556 | ", total_msat" |
| 4557 | ", partid" |
| 4558 | ", local_invreq_id" |
| 4559 | ", groupid" |
| 4560 | ", completed_at" |
| 4561 | " FROM payments" |
| 4562 | " WHERE" |
| 4563 | " payment_hash = ?" |
| 4564 | " ORDER BY id;")); |
| 4565 | db_bind_sha256(stmt, payment_hash); |
| 4566 | db_query_prepared(stmt); |
| 4567 | return payments_next(wallet, stmt); |
| 4568 | } |
| 4569 | |
| 4570 | struct db_stmt *payments_by_label(struct wallet *wallet, |
| 4571 | const struct json_escape *label) |
no test coverage detected