From 0e6113b7658af6020b29e0b945b2a084d11ef740 Mon Sep 17 00:00:00 2001 From: ecoolper Date: Wed, 19 Apr 2017 10:39:06 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A0=BC=E5=BC=8F=E5=8C=96=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../binarywang/wxpay/service/impl/WxPayServiceImpl.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/weixin-java-pay/src/main/java/com/github/binarywang/wxpay/service/impl/WxPayServiceImpl.java b/weixin-java-pay/src/main/java/com/github/binarywang/wxpay/service/impl/WxPayServiceImpl.java index ed609c23..2572f091 100644 --- a/weixin-java-pay/src/main/java/com/github/binarywang/wxpay/service/impl/WxPayServiceImpl.java +++ b/weixin-java-pay/src/main/java/com/github/binarywang/wxpay/service/impl/WxPayServiceImpl.java @@ -375,7 +375,6 @@ public class WxPayServiceImpl implements WxPayService { } /** - * 由于暂时未找到使用jodd-http实现证书配置的办法,故而暂时使用httpclient * ecoolper(20170418),修改为jodd-http方式 */ private String postWithKey(String url, String requestStr) throws WxErrorException { @@ -385,9 +384,9 @@ public class WxPayServiceImpl implements WxPayService { sslContext = this.getConfig().initSSLContext(); } - HttpRequest request =HttpRequest.post(url).withConnectionProvider(new SSLSocketHttpConnectionProvider(sslContext)); + HttpRequest request = HttpRequest.post(url).withConnectionProvider(new SSLSocketHttpConnectionProvider(sslContext)); request.bodyText(requestStr); - HttpResponse response =request.send(); + HttpResponse response = request.send(); String result = response.bodyText(); this.log.debug("\n[URL]: {}\n[PARAMS]: {}\n[RESPONSE]: {}", url, requestStr, result); return result;