diff --git a/designer-base/src/main/java/com/fr/env/detect/impl/JarInconsistentDetector.java b/designer-base/src/main/java/com/fr/env/detect/impl/JarInconsistentDetector.java index b13195067b..e10f18052c 100644 --- a/designer-base/src/main/java/com/fr/env/detect/impl/JarInconsistentDetector.java +++ b/designer-base/src/main/java/com/fr/env/detect/impl/JarInconsistentDetector.java @@ -114,7 +114,11 @@ public class JarInconsistentDetector extends AbstractExceptionDetector { // 获取所有的不一致的 build List inConsistentInfos = buildInfos.stream() - .filter((e) -> !StringUtils.equals(designerBuild.get(), e.getGroupBuild())) + .filter((e) -> { + // 不为空,且不相等 + return StringUtils.isNotEmpty(e.getGroupBuild()) + && !StringUtils.equals(designerBuild.get(), e.getGroupBuild()); + }) .collect(Collectors.toList()); // 没有直接返回 @@ -141,7 +145,9 @@ public class JarInconsistentDetector extends AbstractExceptionDetector { for (BuildInfo localInfo : localInfos) { String jar = localInfo.getJar(); String groupContent = localInfo.getGroupBuild(); - localMap.put(jar, groupContent); + if (StringUtils.isNotEmpty(groupContent)) { + localMap.put(jar, groupContent); + } } return localMap; }