diff --git a/lucene/backward-codecs/src/test/org/apache/lucene/backward_codecs/lucene94/Lucene94HnswVectorsWriter.java b/lucene/backward-codecs/src/test/org/apache/lucene/backward_codecs/lucene94/Lucene94HnswVectorsWriter.java index 9b957f2f13b5..f3febe8c5c91 100644 --- a/lucene/backward-codecs/src/test/org/apache/lucene/backward_codecs/lucene94/Lucene94HnswVectorsWriter.java +++ b/lucene/backward-codecs/src/test/org/apache/lucene/backward_codecs/lucene94/Lucene94HnswVectorsWriter.java @@ -639,10 +639,7 @@ public void addValue(int docID, Object value) throws IOException { assert docID > lastDocID; docsWithField.add(docID); vectors.add(copyValue(vectorValue)); - if (node > 0) { - // start at node 1! node 0 is added implicitly, in the constructor - hnswGraphBuilder.addGraphNode(node, vectorValue); - } + hnswGraphBuilder.addGraphNode(node, vectorValue); node++; lastDocID = docID; }