Skip to content

Commit 62623fe

Browse files
committed
Improved code a bit.
1 parent 5b19702 commit 62623fe

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

jenkins-client/src/main/java/com/offbytwo/jenkins/JenkinsServer.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -700,7 +700,7 @@ public void deleteJob(FolderJob folder, String jobName, boolean crumbFlag) throw
700700
* @throws IOException in case of an error.
701701
*/
702702
public void deleteJob(String jobName) throws IOException {
703-
client.post("/job/" + EncodingUtils.encode(jobName) + "/doDelete");
703+
deleteJob(jobName, false);
704704
}
705705

706706
/**
@@ -722,7 +722,7 @@ public void deleteJob(String jobName, boolean crumbFlag) throws IOException {
722722
* @throws IOException in case of an error.
723723
*/
724724
public void disableJob(String jobName) throws IOException {
725-
client.post("/job/" + EncodingUtils.encode(jobName) + "/disable");
725+
disableJob(jobName, false);
726726
}
727727

728728
/**
@@ -744,7 +744,7 @@ public void disableJob(String jobName, boolean crumbFlag) throws IOException {
744744
* @throws IOException In case of an failure.
745745
*/
746746
public void enableJob(String jobName) throws IOException {
747-
client.post("/job/" + EncodingUtils.encode(jobName) + "/enable");
747+
enableJob( jobName, false );
748748
}
749749

750750
/**

0 commit comments

Comments
 (0)