From d96959d75b7faabae857545eb7d39d4476dda7b0 Mon Sep 17 00:00:00 2001 From: zyh <1124596031@qq.com> Date: Tue, 7 Apr 2020 16:21:15 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0readme?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 19c9017..ea96516 100644 --- a/README.md +++ b/README.md @@ -419,11 +419,13 @@ method: "GET", success: res => { setTimeout(_ => { + opt['success'] && opt['success'](res.data); resolve(res.data) }, 0) }, fail: err => { - reject(err); + opt['fail'] && opt['fail'](err); + reject(err) } }) }) @@ -442,10 +444,12 @@ method: "POST", success: res => { setTimeout(_ => { + opt['success'] && opt['success'](res.data); resolve(res.data) }, 0) }, fail: err => { + opt['fail'] && opt['fail'](err); reject(err) } })