Skip to content

Commit

Permalink
[JENKINS-42310] JobAssignedLabel Lint defect support Maven and Matrix…
Browse files Browse the repository at this point in the history
… projects
  • Loading branch information
v1v committed Feb 24, 2017
1 parent 13f711c commit 71d0f80
Showing 1 changed file with 3 additions and 2 deletions.
@@ -1,7 +1,7 @@
package org.jenkins.ci.plugins.jenkinslint.check;

import hudson.model.Item;
import hudson.model.Project;
import hudson.model.AbstractProject;
import org.jenkins.ci.plugins.jenkinslint.model.AbstractCheck;

/**
Expand All @@ -16,6 +16,7 @@ public JobAssignedLabelChecker() {
}

public boolean executeCheck(Item item) {
return item instanceof Project && (((Project) item).getAssignedLabelString() == null || ((Project) item).getAssignedLabelString().length() == 0);
return item instanceof AbstractProject && (((AbstractProject) item).getAssignedLabelString() == null ||
((AbstractProject) item).getAssignedLabelString().length() == 0);
}
}

0 comments on commit 71d0f80

Please sign in to comment.