Fix the DocumentsIdsIter and do not iter on an Option

This commit is contained in:
Clément Renault 2019-10-10 18:32:22 +02:00
parent 543b65b09b
commit 9dca18f966
No known key found for this signature in database
GPG Key ID: 92ADA4E935E71FA4

View File

@ -144,7 +144,7 @@ impl<'r> Iterator for DocumentsIdsIter<'r> {
type Item = Result<DocumentId, rkv::StoreError>; type Item = Result<DocumentId, rkv::StoreError>;
fn next(&mut self) -> Option<Self::Item> { fn next(&mut self) -> Option<Self::Item> {
for result in self.iter.next() { for result in &mut self.iter {
match result { match result {
Ok((key, _)) => { Ok((key, _)) => {
let array = TryFrom::try_from(key).unwrap(); let array = TryFrom::try_from(key).unwrap();