Add pagination to Nextflow release list

This commit is contained in:
Thomas A. Christensen II 2022-09-29 15:33:03 -05:00
parent f9b3f5cc17
commit 0c9c29b594
Signed by: millironx
GPG key ID: 139C07724802BC5D

View file

@ -9,9 +9,11 @@ import semver = require("semver");
const NEXTFLOW_REPO = { owner: "nextflow-io", repo: "nextflow" };
async function all_nf_releases(ok) {
const { data: releases } = await ok.rest.repos.listReleases(NEXTFLOW_REPO);
return releases;
return await ok.paginate(
ok.rest.repos.listReleases,
NEXTFLOW_REPO,
(response) => response.data
);
}
async function latest_stable_release_data(ok) {