Browse Source

优化WxError类的toString方法,避免输出重复内容

master
BinaryWang 8 years ago
parent
commit
49d561c117
1 changed files with 4 additions and 1 deletions
  1. +4
    -1
      weixin-java-common/src/main/java/me/chanjar/weixin/common/bean/result/WxError.java

+ 4
- 1
weixin-java-common/src/main/java/me/chanjar/weixin/common/bean/result/WxError.java View File

@@ -50,7 +50,10 @@ public class WxError implements Serializable {

@Override
public String toString() {
return "微信错误: errcode=" + errorCode + ", errmsg=" + errorMsg + "\njson:" + json;
if(json != null){
return json;
}
return "错误: Code=" + errorCode + ", Msg=" + errorMsg;
}

public static Builder newBuilder(){


Loading…
Cancel
Save