diff --git a/milli/src/update/facet/bulk.rs b/milli/src/update/facet/bulk.rs index d2205f9d6..297d189cd 100644 --- a/milli/src/update/facet/bulk.rs +++ b/milli/src/update/facet/bulk.rs @@ -4,7 +4,6 @@ use std::io::BufReader; use grenad::CompressionType; use heed::types::ByteSlice; use heed::{BytesEncode, Error, RoTxn, RwTxn}; -use obkv::KvReader; use roaring::RoaringBitmap; use super::{FACET_GROUP_SIZE, FACET_MIN_LEVEL_SIZE}; @@ -13,7 +12,7 @@ use crate::heed_codec::facet::{ FacetGroupKey, FacetGroupKeyCodec, FacetGroupValue, FacetGroupValueCodec, }; use crate::heed_codec::ByteSliceRefCodec; -use crate::update::del_add::DelAdd; +use crate::update::del_add::{DelAdd, KvReaderDelAdd}; use crate::update::index_documents::{create_writer, valid_lmdb_key, writer_into_reader}; use crate::{CboRoaringBitmapCodec, FieldId, Index, Result}; @@ -135,7 +134,7 @@ impl FacetsUpdateBulkInner { if !valid_lmdb_key(key) { continue; } - let value: KvReader = KvReader::new(value); + let value = KvReaderDelAdd::new(value); // DB is empty, it is safe to ignore Del operations let Some(value) = value.get(DelAdd::Addition) else { @@ -159,7 +158,7 @@ impl FacetsUpdateBulkInner { continue; } - let value: KvReader = KvReader::new(value); + let value = KvReaderDelAdd::new(value); // the value is a CboRoaringBitmap, but I still need to prepend the // group size for level 0 (= 1) to it