|
|
@@ -632,6 +632,14 @@ async function hbRequest(config, data) {
|
|
|
}).catch(err => {
|
|
|
const msg = `请求发送异常\n${JSON.stringify(err)}`;
|
|
|
magicJS.logger.error(msg);
|
|
|
+ if(response.body){
|
|
|
+ if (baseConfig.encrypt) {
|
|
|
+ if (typeof body === "string") {
|
|
|
+ let rspText = decryptAES(body.trim(), baseConfig.k, baseConfig.v);
|
|
|
+ err.message = `${err.message}\n${rspText}`;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
return {
|
|
|
code: 2000,
|
|
|
message: `Response Exception: ${err.message}`
|