Don't mark [""] as empty facet

This commit is contained in:
Louis Dureuil 2024-11-20 11:00:26 +01:00 committed by Clément Renault
parent ca779c21f9
commit f893b5153e
No known key found for this signature in database
GPG Key ID: F250A4C4E3AE5F5F

View File

@ -251,7 +251,7 @@ impl FacetedDocidsExtractor {
buffer.extend_from_slice(&fid.to_be_bytes());
cache_fn(cached_sorter, &buffer, docid)
}
Value::String(_) => {
Value::String(_) if depth == perm_json_p::Depth::OnBaseKey => {
buffer.clear();
buffer.push(FacetKind::Empty as u8);
buffer.extend_from_slice(&fid.to_be_bytes());