From d1c1f95420dd12dc9cfb72855c46de6fd419d63f Mon Sep 17 00:00:00 2001 From: holgerhuang <1577594730@qq.com> Date: Thu, 20 Feb 2020 14:14:58 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=B3=E8=AF=B7=E9=80=80=E6=AC=BE=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3=E5=A4=B1=E8=B4=A5=E6=97=B6=E8=BF=94=E5=9B=9E=20?= =?UTF-8?q?=E8=A7=A3=E6=9E=90=E5=A5=BD=E7=9A=84json=E4=B8=B2=EF=BC=8C?= =?UTF-8?q?=E6=96=B9=E4=BE=BF=E6=8B=BF=E5=88=B0=E9=94=99=E8=AF=AF=E5=8E=9F?= =?UTF-8?q?=E5=9B=A0err=5Fcode=5Fdes=E5=B1=95=E7=A4=BA=EF=BC=8C=E8=80=8C?= =?UTF-8?q?=E4=B8=8D=E6=98=AF=E7=9B=B4=E6=8E=A5throw=E4=B8=80=E4=B8=AA?= =?UTF-8?q?=E9=94=99=E8=AF=AF=E7=A0=81err=5Fcode?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/index.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/index.js b/lib/index.js index bfcc2db..01003a7 100644 --- a/lib/index.js +++ b/lib/index.js @@ -84,6 +84,7 @@ class Payment { switch (type) { case 'middleware_nativePay': + case 'refund': break; default: if (json.return_code !== 'SUCCESS') throw new Error(json.return_msg || 'XMLDataError'); @@ -93,6 +94,7 @@ class Payment { case 'middleware_refund': case 'middleware_nativePay': case 'getsignkey': + case 'refund': break; default: if (json.result_code !== 'SUCCESS') throw new Error(json.err_code || 'XMLDataError');