mirror of
https://github.com/meilisearch/MeiliSearch
synced 2024-11-22 21:04:27 +01:00
Insert dump_reader.date() into create_raw_index(_) argument
This commit is contained in:
parent
0893b175dc
commit
df176aaf01
@ -289,8 +289,13 @@ fn import_dump(
|
||||
let mut index_reader = index_reader?;
|
||||
let metadata = index_reader.metadata();
|
||||
log::info!("Importing index `{}`.", metadata.uid);
|
||||
//let date = Some((time::OffsetDateTime::now_utc(), time::OffsetDateTime::now_utc()));
|
||||
let date = dump_reader.date();
|
||||
let date;
|
||||
if let Some(dump_reader_date) = dump_reader.date() {
|
||||
date = Some((dump_reader_date, dump_reader_date));
|
||||
} else {
|
||||
date = Some((time::OffsetDateTime::now_utc(), time::OffsetDateTime::now_utc()));
|
||||
}
|
||||
|
||||
let index = index_scheduler.create_raw_index(&metadata.uid, date)?;
|
||||
|
||||
let mut wtxn = index.write_txn()?;
|
||||
|
Loading…
Reference in New Issue
Block a user