Skip to content
Permalink
Browse files
[FIXED JENKINS-17451] "projects tied to slave" shows unrelated maven
module jobs. shows TopLevelItem only.

Restricts displayed projects to TopLevelItem only.
(cherry picked from commit 9cb0d11)
  • Loading branch information
Vlatombe authored and olivergondza committed Sep 13, 2013
1 parent 0b5f6b2 commit a01c6c5d4c7b54106f31c7746849979b0776e206
Showing with 1 addition and 1 deletion.
  1. +1 −1 core/src/main/java/hudson/model/Label.java
@@ -344,7 +344,7 @@ private String toString(Collection<? extends ModelObject> model) {
public List<AbstractProject> getTiedJobs() {
List<AbstractProject> r = new ArrayList<AbstractProject>();
for (AbstractProject<?,?> p : Jenkins.getInstance().getAllItems(AbstractProject.class)) {
if(this.equals(p.getAssignedLabel()))
if(p instanceof TopLevelItem && this.equals(p.getAssignedLabel()))
r.add(p);
}
return r;

0 comments on commit a01c6c5

Please sign in to comment.