Apache Lucene open-source search software
don't create unnecessary lambda
Mike McCandless7cffae3a16f7
diff --git a/lucene/core/src/java/org/apache/lucene/index/IndexWriterConfig.java b/lucene/core/src/java/org/apache/lucene/index/IndexWriterConfig.javaindex ce4f0a8e5c3..1e1e795d50b 100644--- a/lucene/core/src/java/org/apache/lucene/index/IndexWriterConfig.java+++ b/lucene/core/src/java/org/apache/lucene/index/IndexWriterConfig.java@@ -476,7 +476,7 @@ public final class IndexWriterConfig extends LiveIndexWriterConfig {}}this.indexSort = sort;- this.indexSortFields = Arrays.stream(sort.getSort()).map((s) -> s.getField()).collect(Collectors.toSet());+ this.indexSortFields = Arrays.stream(sort.getSort()).map(SortField::getField).collect(Collectors.toSet());return this;}