diff --git a/server/src/main/java/org/opensearch/index/mapper/IpFieldMapper.java b/server/src/main/java/org/opensearch/index/mapper/IpFieldMapper.java index 05bbad5a675c3..3f7cdc4b55169 100644 --- a/server/src/main/java/org/opensearch/index/mapper/IpFieldMapper.java +++ b/server/src/main/java/org/opensearch/index/mapper/IpFieldMapper.java @@ -40,7 +40,6 @@ import org.apache.lucene.search.MatchNoDocsQuery; import org.apache.lucene.search.PointRangeQuery; import org.apache.lucene.search.Query; -import org.apache.lucene.search.TermQuery; import org.apache.lucene.util.ArrayUtil; import org.apache.lucene.util.BytesRef; import org.opensearch.Version; @@ -243,10 +242,7 @@ public Query termQuery(Object value, @Nullable QueryShardContext context) { } } if (isSearchable() && hasDocValues()) { - return new IndexOrDocValuesQuery( - query, - SortedSetDocValuesField.newSlowExactQuery(name(), ((BytesRef) value)) - ); + return new IndexOrDocValuesQuery(query, SortedSetDocValuesField.newSlowExactQuery(name(), ((BytesRef) value))); } if (hasDocValues()) { return SortedSetDocValuesField.newSlowExactQuery(name(), ((BytesRef) value));