| 1759 | } |
| 1760 | |
| 1761 | static struct command_result *updated_list_done(struct command *cmd, |
| 1762 | const char *method, |
| 1763 | const char *buf, |
| 1764 | const jsmntok_t *result, |
| 1765 | struct db_query *dbq) |
| 1766 | { |
| 1767 | struct table_desc *td = dbq->tables[0]; |
| 1768 | struct command_result *ret; |
| 1769 | u64 unused = 0; |
| 1770 | |
| 1771 | /* We don't care what max created_index it processes. */ |
| 1772 | ret = process_json_result(cmd, buf, result, td, true, &unused, &td->last_updated_index, |
| 1773 | NULL); |
| 1774 | if (ret) |
| 1775 | return ret; |
| 1776 | |
| 1777 | /* Now we can process any new ones */ |
| 1778 | if (td->refresh_needs & REFRESH_CREATED) { |
| 1779 | plugin_log(cmd->plugin, LOG_DBG, |
| 1780 | "%s: records created, inserting from %"PRIu64, td->name, td->last_created_index + 1); |
| 1781 | return refresh_by_created_index(cmd, td, dbq); |
| 1782 | } |
| 1783 | |
| 1784 | return one_refresh_done(cmd, dbq, false); |
| 1785 | } |
| 1786 | |
| 1787 | static struct command_result *paginated_refresh(struct command *cmd, |
| 1788 | struct table_desc *td, |
nothing calls this directly
no test coverage detected