From 1d23622bcea2e026f201e31f7ecdeec2690eecc7 Mon Sep 17 00:00:00 2001 From: yuntian001 Date: Tue, 18 Jul 2023 18:10:09 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E6=B7=B1=E5=BA=A6?= =?UTF-8?q?=E4=BB=A3=E7=90=86=E5=80=BC=E8=A2=AB=E8=AE=BE=E7=BD=AE=E4=B8=BA?= =?UTF-8?q?null=E6=97=B6=E5=87=BA=E9=94=99=E7=9A=84bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/helper.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/utils/helper.ts b/src/utils/helper.ts index f9e81e49..a185a3b5 100644 --- a/src/utils/helper.ts +++ b/src/utils/helper.ts @@ -104,7 +104,7 @@ export const getColorLuma = function (color: string) { export const proxyValue = | any[]>(value: T, update: () => void): T => { return new Proxy(value, { get: function (obj, prop) { - if (typeof obj[prop as keyof T] === 'object') { + if (obj[prop as keyof T] && typeof obj[prop as keyof T] === 'object') { return proxyValue(obj[prop as keyof T] as T, update); } return obj[prop as keyof T];