Преглед на файлове

修改http请求工具类入参拼写错误

大水牛 преди 7 години
родител
ревизия
34533c16b9
No account linked to committer's email
променени са 1 файла, в които са добавени 3 реда и са изтрити 3 реда
  1. 3 3
      xxl-job-core/src/main/java/com/xxl/job/core/util/HttpClientUtil.java

+ 3 - 3
xxl-job-core/src/main/java/com/xxl/job/core/util/HttpClientUtil.java Целия файл

@@ -26,7 +26,7 @@ public class HttpClientUtil {
26 26
 	/**
27 27
 	 * post request
28 28
 	 */
29
-	public static byte[] postRequest(String reqURL, byte[] date) throws Exception {
29
+	public static byte[] postRequest(String reqURL, byte[] data) throws Exception {
30 30
 		byte[] responseBytes = null;
31 31
 		
32 32
 		HttpPost httpPost = new HttpPost(reqURL);
@@ -53,8 +53,8 @@ public class HttpClientUtil {
53 53
 			httpPost.setConfig(requestConfig);
54 54
 
55 55
 			// data
56
-			if (date != null) {
57
-				httpPost.setEntity(new ByteArrayEntity(date, ContentType.DEFAULT_BINARY));
56
+			if (data != null) {
57
+				httpPost.setEntity(new ByteArrayEntity(data, ContentType.DEFAULT_BINARY));
58 58
 			}
59 59
 			// do post
60 60
 			HttpResponse response = httpClient.execute(httpPost);