From 8239f286c2cca585b6b2234f00c93a9cc235027e Mon Sep 17 00:00:00 2001 From: song-tianyang Date: Tue, 23 Nov 2021 14:29:30 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E5=8A=9F=E8=83=BD=E7=94=A8=E4=BE=8B):=20?= =?UTF-8?q?=E4=BF=AE=E5=A4=8DXmind=E5=AF=BC=E5=85=A5=E6=97=B6=E5=87=BA?= =?UTF-8?q?=E7=8E=B0=E6=A1=88=E4=BE=8B=E6=A0=87=E7=AD=BE=E4=B8=BA=E7=A9=BA?= =?UTF-8?q?=E6=95=B0=E7=BB=84=E7=9A=84=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修复Xmind导入时出现案例标签为空数组的错误 --- .../src/main/java/io/metersphere/xmind/XmindCaseParser.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/backend/src/main/java/io/metersphere/xmind/XmindCaseParser.java b/backend/src/main/java/io/metersphere/xmind/XmindCaseParser.java index 5c42289b26..f75b6920a2 100644 --- a/backend/src/main/java/io/metersphere/xmind/XmindCaseParser.java +++ b/backend/src/main/java/io/metersphere/xmind/XmindCaseParser.java @@ -404,7 +404,10 @@ public class XmindCaseParser { rc.append(replace(item.getTitle(), RC_REGEX)); rc.append("\n"); } else if (isAvailable(item.getTitle(), TAG_REGEX)) { - tags.add(replace(item.getTitle(), TAG_REGEX)); + String tag = replace(item.getTitle(), TAG_REGEX); + if (StringUtils.isNotEmpty(tag)) { + tags.add(tag); + } } else if (isAvailable(item.getTitle(), ID_REGEX)) { customId.append(replace(item.getTitle(), ID_REGEX)); } else {