diff --git a/app/api/CircleCI.js b/app/api/CircleCI.js index e03614b..ce4ad45 100644 --- a/app/api/CircleCI.js +++ b/app/api/CircleCI.js @@ -27,9 +27,9 @@ export async function getProjects() { return await request(url, GET, {}, CIToken).then(JSONify); } -export async function getProjectRecentBuilds(user, repo) { +export async function getProjectRecentBuilds(user, repo, limit = 1) { const CIToken = await token.get(); - const url = endpoints.get('PROJECT_RECENTS').param({ user, repo }).query({ limit: 1}); + const url = endpoints.get('PROJECT_RECENTS').param({ user, repo }).query({ limit }); return await request( url, GET,