feat: Remove the lifetime restriction for Database Updates

This commit is contained in:
Clément Renault 2019-02-06 18:03:41 +01:00
parent 4398b88a3a
commit 1c1f9201b8
No known key found for this signature in database
GPG key ID: 0151CDAB43460DAE
3 changed files with 42 additions and 42 deletions

View file

@ -61,7 +61,7 @@ fn index(
while !end_of_file {
let tokenizer_builder = DefaultBuilder::new();
let mut update = database.update()?;
let mut update = database.start_update()?;
loop {
end_of_file = !rdr.read_record(&mut raw_record)?;
@ -88,7 +88,7 @@ fn index(
println!();
println!("committing update...");
update.commit()?;
database.commit_update(update)?;
}
Ok(database)