Skip to content

Commit

Permalink
Removed special casing for Text.Contains doing pre-submission tokenizing
Browse files Browse the repository at this point in the history
  • Loading branch information
criminosis committed Dec 1, 2023
1 parent ebcb506 commit d55e2df
Showing 1 changed file with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -857,10 +857,8 @@ public String buildQueryFilter(Condition<JanusGraphElement> condition, KeyInform
throw new IllegalArgumentException("Text mapped string values only support CONTAINS and Compare queries and not: " + predicate);
if (map==Mapping.STRING && Text.HAS_CONTAINS.contains(predicate))
throw new IllegalArgumentException("String mapped string values do not support CONTAINS queries: " + predicate);
//Special case
if (predicate == Text.CONTAINS) {
return tokenize(ParameterType.TEXT_ANALYZER, information, value, key, predicate);
} else if (predicate == Text.PREFIX || predicate == Text.CONTAINS_PREFIX
if (predicate == Text.CONTAINS
|| predicate == Text.PREFIX|| predicate == Text.CONTAINS_PREFIX
|| predicate == Text.REGEX || predicate == Text.CONTAINS_REGEX
|| predicate == Text.FUZZY || predicate == Text.CONTAINS_FUZZY) {
return buildQueryFilterStringValue(key, (String) value, predicate, information);
Expand Down

0 comments on commit d55e2df

Please sign in to comment.