Skip to content

Commit

Permalink
[FIXED JENKINS-32822] Displays the checkbox for matrix projects even …
Browse files Browse the repository at this point in the history
…when the publisher is newly added.
  • Loading branch information
ikedam committed Feb 14, 2016
1 parent 1abccf7 commit bb97fe5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 9 deletions.
Expand Up @@ -235,15 +235,9 @@ public Notifier newInstance(StaplerRequest req, JSONObject formData) throws Form

/**
* @return true if the current request is for a matrix project.
* @since 1.16
*/
public boolean isMatrixProject() {
StaplerRequest req = Stapler.getCurrentRequest();
if (req == null) {
return false;
}
Job<?, ?> job = req.findAncestorObject(Job.class);
return (job instanceof MatrixProject);
public boolean isMatrixProject(Object it) {
return (it instanceof MatrixProject);
}
}

Expand Down
Expand Up @@ -22,7 +22,7 @@
<f:entry title="${%Regular expression to search for}" field="regexpForRerun">
<f:textbox />
</f:entry>
<j:if test="${descriptor.matrixProject}">
<j:if test="${descriptor.isMatrixProject(it)}">
<f:entry title="${%Test regular expression for the matrix parent}" field="regexpForMatrixParent">
<f:checkbox />
</f:entry>
Expand Down

0 comments on commit bb97fe5

Please sign in to comment.