From 77d837c01025ec33515e83df7ef8beaf86994827 Mon Sep 17 00:00:00 2001 From: "lihao.ylh" Date: Mon, 28 Feb 2022 16:40:08 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=20=E4=BC=98=E5=8C=96=E5=BD=93=20loop?= =?UTF-8?q?=20=E4=B8=BA=E7=A9=BA=E6=95=B0=E7=BB=84=E6=97=B6,=20=E5=88=A4?= =?UTF-8?q?=E6=96=AD=E4=B8=BA=E6=9C=89=20loop=20=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/designer/src/document/node/node.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/designer/src/document/node/node.ts b/packages/designer/src/document/node/node.ts index 4af456ab5..78d2870bd 100644 --- a/packages/designer/src/document/node/node.ts +++ b/packages/designer/src/document/node/node.ts @@ -501,7 +501,7 @@ export class Node { } /** - * has loop when 1. loop is validArray with length > 1 ; OR 2. loop is variable object + * has loop when 1. loop is valid array ; OR 2. loop is variable object * @return boolean, has loop config or not */ hasLoop() { @@ -510,7 +510,7 @@ export class Node { return false; } - if (Array.isArray(value) && value.length > 0) { + if (Array.isArray(value)) { return true; } if (isJSExpression(value)) {