🎨 #1189 优化错误异常输出,移除冗余代码

This commit is contained in:
Binary Wang
2019-09-05 12:31:26 +08:00
parent eecd4bec76
commit 8ab4af031a
81 changed files with 789 additions and 800 deletions

View File

@@ -1,10 +1,6 @@
package me.chanjar.weixin.open.api.impl;
import java.io.IOException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import me.chanjar.weixin.common.WxType;
import me.chanjar.weixin.common.error.WxError;
import me.chanjar.weixin.common.error.WxErrorException;
import me.chanjar.weixin.common.util.http.RequestExecutor;
@@ -12,6 +8,10 @@ import me.chanjar.weixin.common.util.http.RequestHttp;
import me.chanjar.weixin.open.api.WxOpenComponentService;
import me.chanjar.weixin.open.api.WxOpenConfigStorage;
import me.chanjar.weixin.open.api.WxOpenService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.io.IOException;
/**
* @author <a href="https://github.com/007gzs">007</a>
@@ -44,7 +44,7 @@ public abstract class WxOpenServiceAbstractImpl<H, P> implements WxOpenService,
protected synchronized <T, E> T execute(RequestExecutor<T, E> executor, String uri, E data) throws WxErrorException {
try {
T result = executor.execute(uri, data);
T result = executor.execute(uri, data, WxType.Open);
this.log.debug("\n【请求地址】: {}\n【请求参数】{}\n【响应数据】{}", uri, data, result);
return result;
} catch (WxErrorException e) {