File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
src/main/java/com/flagsmith/flagengine/segments Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -27,6 +27,8 @@ public class SegmentEvaluator {
2727 private static Configuration jsonPathConfiguration = Configuration
2828 .defaultConfiguration ()
2929 .setOptions (Option .SUPPRESS_EXCEPTIONS );
30+ private static TypeReference <List <String >> stringListTypeRef = new TypeReference <List <String >>() {
31+ };
3032
3133 /**
3234 * Check if context is in segment.
@@ -94,8 +96,7 @@ private static Boolean contextMatchesCondition(
9496 try {
9597 // Try parsing a JSON list first
9698 conditionList = mapper .readValue (
97- stringConditionValue , new TypeReference <List <String >>() {
98- });
99+ stringConditionValue , stringListTypeRef );
99100 } catch (IOException e ) {
100101 // As a fallback, split by comma
101102 conditionList = Arrays .asList (stringConditionValue .split ("," ));
You can’t perform that action at this time.
0 commit comments