From 02a886583ac07666013bffbfbd0b0421f6e68792 Mon Sep 17 00:00:00 2001 From: handongxun Date: Sat, 26 Dec 2020 11:56:17 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=20H5=E5=B9=B3=E5=8F=B0?= =?UTF-8?q?=E5=BC=80=E5=8F=91=E7=8E=AF=E5=A2=83=E4=B8=8B=20=E5=B1=9E?= =?UTF-8?q?=E6=80=A7:getone=3D"true"=E6=97=B6=E6=8A=A5=E9=94=99=E7=9A=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uni-cli-shared/components/unicloud-db.vue | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/packages/uni-cli-shared/components/unicloud-db.vue b/packages/uni-cli-shared/components/unicloud-db.vue index fdeeb6695..2188d27ac 100644 --- a/packages/uni-cli-shared/components/unicloud-db.vue +++ b/packages/uni-cli-shared/components/unicloud-db.vue @@ -334,7 +334,12 @@ export default { // #ifdef H5 if (process.env.NODE_ENV === 'development') { this._debugDataList.length = 0 - this._debugDataList.push(...JSON.parse(JSON.stringify(this.dataList))) + let formatData = JSON.parse(JSON.stringify(this.dataList)) + if (Array.isArray(this.dataList)) { + this._debugDataList.push(...formatData) + } else { + this._debugDataList.push(formatData) + } } // #endif }).catch((err) => { -- GitLab