diff --git a/common/src/main/java/com/alibaba/nacos/common/utils/StringUtils.java b/common/src/main/java/com/alibaba/nacos/common/utils/StringUtils.java index ad4d93553a2..3418b625658 100644 --- a/common/src/main/java/com/alibaba/nacos/common/utils/StringUtils.java +++ b/common/src/main/java/com/alibaba/nacos/common/utils/StringUtils.java @@ -192,9 +192,7 @@ public static String join(Collection collection, String separator) { if (objects[i] != null) { stringBuilder.append(objects[i]); if (i != collection.size() - 1 && separator != null) { - if (separator != null) { - stringBuilder.append(separator); - } + stringBuilder.append(separator); } } }