Browse Source

Add missing TreeSet to CollectionFactory.createCollection()

See gh-28949
pull/28959/head
Johnny Lim 3 years ago committed by Stephane Nicoll
parent
commit
ccec75c98d
  1. 2
      spring-core/src/main/java/org/springframework/core/CollectionFactory.java

2
spring-core/src/main/java/org/springframework/core/CollectionFactory.java

@ -191,7 +191,7 @@ public final class CollectionFactory {
else if (LinkedList.class == collectionType) { else if (LinkedList.class == collectionType) {
return new LinkedList<>(); 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<>(); return new TreeSet<>();
} }
else if (EnumSet.class.isAssignableFrom(collectionType)) { else if (EnumSet.class.isAssignableFrom(collectionType)) {

Loading…
Cancel
Save