| 307 | } |
| 308 | |
| 309 | struct command_result *bwatch_poll_chain(struct command *cmd, |
| 310 | void *unused UNUSED) |
| 311 | { |
| 312 | struct bwatch *bwatch = bwatch_of(cmd->plugin); |
| 313 | struct out_req *req; |
| 314 | |
| 315 | req = jsonrpc_request_start(cmd, "getchaininfo", |
| 316 | getchaininfo_done, getchaininfo_failed, |
| 317 | NULL); |
| 318 | json_add_u32(req->js, "last_height", bwatch->current_height); |
| 319 | return send_outreq(req); |
| 320 | } |
| 321 | |
| 322 | /* |
| 323 | * ============================================================================ |
nothing calls this directly
no test coverage detected