[Jenkins Backend Plugin] Fix regression https://github.com/backstage/… (#1457)

* [Jenkins Backend Plugin] Fix regression https://github.com/backstage/community-plugins/pull/796

Fix regression introduced by https://github.com/backstage/community-plugins/pull/796

Signed-off-by: Skiepp <skiepp93@hotmail.it>

* +changeset

Signed-off-by: Skiepp <skiepp93@hotmail.it>

* +changeset description

Signed-off-by: Skiepp <skiepp93@hotmail.it>

---------

Signed-off-by: Skiepp <skiepp93@hotmail.it>
This commit is contained in:
Skiepp 2024-10-02 21:55:14 +02:00 committed by GitHub
parent 442793ced5
commit 33065641e8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 7 additions and 1 deletions

View File

@ -0,0 +1,5 @@
---
'@backstage-community/plugin-jenkins-backend': patch
---
Fix [#796](https://github.com/backstage/community-plugins/pull/796) regression

View File

@ -118,9 +118,10 @@ export class JenkinsApiImpl {
const isStandaloneProject = !project.jobs;
if (isStandaloneProject) {
const limitedStandaloneJobTreeSpec = `${JenkinsApiImpl.jobTreeSpec}{0,${jenkinsInfo.projectCountLimit}}`;
const standaloneProject = await client.job.get({
name: jenkinsInfo.jobFullName,
tree: limitedJobsTreeSpec.replace(/\s/g, ''),
tree: limitedStandaloneJobTreeSpec.replace(/\s/g, ''),
});
projects.push(this.augmentProject(standaloneProject));
return projects;