Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKevin Sawicki2012-05-08 18:39:11 -0400
committerKevin Sawicki2012-05-09 11:20:27 -0400
commit3ef0763049f682ceb0f1d6d256a0e7dd80a2982b (patch)
tree7b11062df56bf7135d5e70db9601d5787dfd632d
parent0144a9f959348751cb24be2e289327d065c8ebb5 (diff)
downloadegit-github-3ef0763049f682ceb0f1d6d256a0e7dd80a2982b.tar.gz
egit-github-3ef0763049f682ceb0f1d6d256a0e7dd80a2982b.tar.xz
egit-github-3ef0763049f682ceb0f1d6d256a0e7dd80a2982b.zip
Don't call sendParams when params are null
Setting the content length on an empty DELETE request is not needed Change-Id: I7e0e0e18b3ae262751d9feeb924a8dbc0277af3b
-rw-r--r--org.eclipse.egit.github.core/src/org/eclipse/egit/github/core/client/GitHubClient.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/org.eclipse.egit.github.core/src/org/eclipse/egit/github/core/client/GitHubClient.java b/org.eclipse.egit.github.core/src/org/eclipse/egit/github/core/client/GitHubClient.java
index 26f84b2e..99340ea0 100644
--- a/org.eclipse.egit.github.core/src/org/eclipse/egit/github/core/client/GitHubClient.java
+++ b/org.eclipse.egit.github.core/src/org/eclipse/egit/github/core/client/GitHubClient.java
@@ -706,7 +706,8 @@ public class GitHubClient {
public void delete(final String uri, final Object params)
throws IOException {
HttpURLConnection request = createDelete(uri);
- sendParams(request, params);
+ if (params != null)
+ sendParams(request, params);
final int code = request.getResponseCode();
updateRateLimits(request);
if (!isEmpty(code))

Back to the top