Skip to content

Commit

Permalink
Merge pull request #9 from fbelzunc/JENKINS-26805
Browse files Browse the repository at this point in the history
[FIXED JENKINS-26805] Job not triggered after git merge on a branch
  • Loading branch information
fbelzunc committed Feb 8, 2015
2 parents c70f028 + de63f6c commit 89b6505
Showing 1 changed file with 0 additions and 6 deletions.
Expand Up @@ -9,7 +9,6 @@
import hudson.scm.SCM;
import hudson.security.ACL;
import jenkins.model.Jenkins;
import net.sf.json.JSONArray;
import net.sf.json.JSONObject;
import org.acegisecurity.context.SecurityContext;
import org.acegisecurity.context.SecurityContextHolder;
Expand Down Expand Up @@ -106,11 +105,6 @@ private void processPayload(JSONObject payload) {
String url = payload.getString("canon_url") + repo.getString("absolute_url");
LOGGER.info("Received commit hook notification for "+repo);

JSONArray commits = payload.getJSONArray("commits");
int last = commits.size() - 1;
String sha1 = commits.getJSONObject(last).getString("raw_node");
String branch = commits.getJSONObject(last).getString("branch");

String scm = repo.getString("scm");
if ("git".equals(scm)) {
SecurityContext old = Jenkins.getInstance().getACL().impersonate(ACL.SYSTEM);
Expand Down

0 comments on commit 89b6505

Please sign in to comment.