clarify "unsupported [database] version" error message
When using an incompatible database version (e.g. from an old install of zoxide) this message is displayed frequently. The message should provide helpful information about the underlying problem and possible solution(s).
This commit is contained in:
parent
6dedfcd74a
commit
b10f598e66
|
|
@ -226,7 +226,10 @@ impl Database {
|
||||||
deserializer.deserialize(bytes_dirs).context("could not deserialize database")?
|
deserializer.deserialize(bytes_dirs).context("could not deserialize database")?
|
||||||
}
|
}
|
||||||
version => {
|
version => {
|
||||||
bail!("unsupported version (got {version}, supports {})", Self::VERSION)
|
bail!(
|
||||||
|
"unsupported database version (got {version}, supports {}), re-create the database",
|
||||||
|
Self::VERSION
|
||||||
|
)
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue