diff --git a/spring-core/src/main/java/org/springframework/core/CollectionFactory.java b/spring-core/src/main/java/org/springframework/core/CollectionFactory.java index 15e3ee77538..5a2bb2bb45a 100644 --- a/spring-core/src/main/java/org/springframework/core/CollectionFactory.java +++ b/spring-core/src/main/java/org/springframework/core/CollectionFactory.java @@ -191,7 +191,7 @@ public final class CollectionFactory { else if (LinkedList.class == collectionType) { return new LinkedList<>(); } - else if (SortedSet.class == collectionType || NavigableSet.class == collectionType) { + else if (TreeSet.class == collectionType || SortedSet.class == collectionType || NavigableSet.class == collectionType) { return new TreeSet<>(); } else if (EnumSet.class.isAssignableFrom(collectionType)) {