Skip to content

Commit

Permalink
Remove unused points declaration
Browse files Browse the repository at this point in the history
Signed-off-by: Harsha Vamsi Kalluri <[email protected]>
  • Loading branch information
harshavamsi committed Dec 8, 2023
1 parent 1dbdfdd commit 7e83aa9
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -912,18 +912,17 @@ public Query termsQuery(String field, List<Object> values, boolean hasDocValues,
if (upTo != v.length) {
v = Arrays.copyOf(v, upTo);
}
long points[] = v.clone();
if (isSearchable && hasDocValues) {
return new IndexOrDocValuesQuery(
LongPoint.newSetQuery(field, points),
SortedNumericDocValuesField.newSlowSetQuery(field, points)
LongPoint.newSetQuery(field, v),
SortedNumericDocValuesField.newSlowSetQuery(field, v)
);
}
if (hasDocValues) {
return SortedNumericDocValuesField.newSlowSetQuery(field, points);
return SortedNumericDocValuesField.newSlowSetQuery(field, v);

}
return LongPoint.newSetQuery(field, points);
return LongPoint.newSetQuery(field, v);
}

@Override
Expand Down Expand Up @@ -1001,7 +1000,8 @@ public Query termQuery(String field, Object value, boolean hasDocValues, boolean
return Queries.newMatchNoDocsQuery("Value [" + value + "] has a decimal part");
}
BigInteger v = parse(value, true);
return rangeQuery(field, v, v, true, true, hasDocValues, isSearchable, null);
return BigIntegerPoint.newExactQuery(field, v);
// return rangeQuery(field, v, v, true, true, hasDocValues, isSearchable, null);
}

@Override
Expand Down

0 comments on commit 7e83aa9

Please sign in to comment.