changeset 1543:1db694d98003

minor
author Franklin Schmidt <fschmidt@gmail.com>
date Sun, 20 Sep 2020 16:45:31 -0600
parents d4407e8de707
children 35601f15ecc3
files src/luan/modules/lucene/LuceneIndex.java
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/luan/modules/lucene/LuceneIndex.java	Sun Sep 20 15:53:58 2020 -0600
+++ b/src/luan/modules/lucene/LuceneIndex.java	Sun Sep 20 16:45:31 2020 -0600
@@ -223,6 +223,8 @@
 		return new Term(key,br);
 	}
 
+	private static final Set<String> ID_SET = Collections.singleton("id");
+
 	private void backupDelete(Query query)
 		throws IOException, SQLException, LuanException
 	{
@@ -232,7 +234,7 @@
 			try {
 				MyCollector col = new MyCollector() {
 					@Override public void collect(int iDoc) throws IOException {
-						Document doc = searcher.doc( docBase + iDoc );
+						Document doc = searcher.doc( docBase + iDoc, ID_SET );
 						Long id = (Long)doc.getField("id").numericValue();
 						ids.add(id);
 					}