| 300 | } |
| 301 | |
| 302 | struct command_result *bwatch_send_chaininfo(struct command *cmd, |
| 303 | void *unused UNUSED) |
| 304 | { |
| 305 | struct bwatch *bwatch = bwatch_of(cmd->plugin); |
| 306 | struct out_req *req; |
| 307 | |
| 308 | req = jsonrpc_request_start(cmd, "getchaininfo", |
| 309 | chaininfo_getchaininfo_done, |
| 310 | chaininfo_getchaininfo_failed, |
| 311 | NULL); |
| 312 | json_add_u32(req->js, "last_height", bwatch->current_height); |
| 313 | return send_outreq(req); |
| 314 | } |
| 315 | |
| 316 | /* |
| 317 | * ============================================================================ |
nothing calls this directly
no test coverage detected