Skip to content

Commit

Permalink
ParamConverterFactory should use LinkedHashSet to preserve ordering (#…
Browse files Browse the repository at this point in the history
…3670) (#3955)

Signed-off-by: Christian Kaltepoth <christian@kaltepoth.de>
  • Loading branch information
chkal authored and jansupol committed Oct 4, 2018
1 parent 1e881fe commit 02631b4
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import java.lang.annotation.Annotation;
import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Set;

Expand Down Expand Up @@ -49,7 +49,7 @@ public class ParamConverterFactory implements ParamConverterProvider {

ParamConverterFactory(Set<ParamConverterProvider> providers, Set<ParamConverterProvider> customProviders) {

Set<ParamConverterProvider> copyProviders = new HashSet<>(providers);
Set<ParamConverterProvider> copyProviders = new LinkedHashSet<>(providers);
converterProviders = new ArrayList<>();
converterProviders.addAll(customProviders);
copyProviders.removeAll(customProviders);
Expand Down

0 comments on commit 02631b4

Please sign in to comment.