Do not assume v1.12 when there is no index-scheduler version

This commit is contained in:
Louis Dureuil 2025-01-23 17:16:53 +01:00
parent 718a98fbbf
commit c1e5897076
No known key found for this signature in database

View File

@ -47,13 +47,10 @@ impl Versioning {
let this = Self { version };
let from = match this.get_version(&wtxn)? {
Some(version) => version,
// fresh DB: use the db version
None => {
let assumed_version = match db_version {
(1, 12, _) => db_version,
_ => (1, 12, 7),
};
this.set_version(&mut wtxn, assumed_version)?;
assumed_version
this.set_version(&mut wtxn, db_version)?;
db_version
}
};
wtxn.commit()?;