From 4e30513c4b88913ca556faffa5a81cfd0effdbc2 Mon Sep 17 00:00:00 2001 From: Matthew Davis Date: Sun, 28 May 2023 11:22:20 -0400 Subject: [PATCH] fix issue in reindex for empty meta or documents --- .../src/main/java/io/zulia/server/index/ShardReader.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/zulia-server/src/main/java/io/zulia/server/index/ShardReader.java b/zulia-server/src/main/java/io/zulia/server/index/ShardReader.java index e8fda3b9..a0cade12 100644 --- a/zulia-server/src/main/java/io/zulia/server/index/ShardReader.java +++ b/zulia-server/src/main/java/io/zulia/server/index/ShardReader.java @@ -653,8 +653,8 @@ protected boolean match(int doc) { if (fullDocValues != null) { fullDocValues.advanceExact(docId); } - BytesRef meta = metaDocValues != null ? metaDocValues.binaryValue() : new BytesRef(BytesRef.EMPTY_BYTES); - BytesRef fullDoc = fullDocValues != null ? fullDocValues.binaryValue() : new BytesRef(BytesRef.EMPTY_BYTES); + BytesRef meta = metaDocValues != null ? metaDocValues.binaryValue() : null; + BytesRef fullDoc = fullDocValues != null ? fullDocValues.binaryValue() : null; documentConsumer.accept(new ReIndexContainer(idDocValues.binaryValue(), meta, fullDoc)); }