mirror of
https://github.com/meilisearch/MeiliSearch
synced 2024-11-12 07:58:54 +01:00
stop casting integer docids to string
This commit is contained in:
parent
adddf3f179
commit
f65153ad64
@ -536,7 +536,7 @@ mod tests {
|
|||||||
|
|
||||||
// Check that this document is equal to the last one sent.
|
// Check that this document is equal to the last one sent.
|
||||||
let mut doc_iter = doc.iter();
|
let mut doc_iter = doc.iter();
|
||||||
assert_eq!(doc_iter.next(), Some((0, &br#""1""#[..])));
|
assert_eq!(doc_iter.next(), Some((0, &b"1"[..])));
|
||||||
assert_eq!(doc_iter.next(), Some((1, &br#""benoit""#[..])));
|
assert_eq!(doc_iter.next(), Some((1, &br#""benoit""#[..])));
|
||||||
assert_eq!(doc_iter.next(), None);
|
assert_eq!(doc_iter.next(), None);
|
||||||
drop(rtxn);
|
drop(rtxn);
|
||||||
@ -562,9 +562,9 @@ mod tests {
|
|||||||
|
|
||||||
// Check that this document is equal to the last one sent.
|
// Check that this document is equal to the last one sent.
|
||||||
let mut doc_iter = doc.iter();
|
let mut doc_iter = doc.iter();
|
||||||
assert_eq!(doc_iter.next(), Some((0, &br#""1""#[..])));
|
assert_eq!(doc_iter.next(), Some((0, &b"1"[..])));
|
||||||
assert_eq!(doc_iter.next(), Some((1, &br#""benoit""#[..])));
|
assert_eq!(doc_iter.next(), Some((1, &br#""benoit""#[..])));
|
||||||
assert_eq!(doc_iter.next(), Some((2, &br#"25"#[..])));
|
assert_eq!(doc_iter.next(), Some((2, &b"25"[..])));
|
||||||
assert_eq!(doc_iter.next(), None);
|
assert_eq!(doc_iter.next(), None);
|
||||||
drop(rtxn);
|
drop(rtxn);
|
||||||
}
|
}
|
||||||
|
@ -171,7 +171,6 @@ impl Transform<'_, '_> {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
serde_json::to_writer(&mut external_id_buffer, &value).unwrap();
|
serde_json::to_writer(&mut external_id_buffer, &value).unwrap();
|
||||||
*bytes = &external_id_buffer;
|
|
||||||
Cow::Owned(value)
|
Cow::Owned(value)
|
||||||
}
|
}
|
||||||
None => {
|
None => {
|
||||||
|
Loading…
Reference in New Issue
Block a user