Skip to content

Commit

Permalink
Pass failed version upgrade message to output
Browse files Browse the repository at this point in the history
  • Loading branch information
sameer committed Aug 6, 2024
1 parent e50e42b commit 32232cf
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
20 changes: 10 additions & 10 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions cli/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -170,9 +170,9 @@ fn main() -> io::Result<()> {
}

let old_version = settings.version.clone();
if let Err(()) = settings.try_upgrade() {
if let Err(msg) = settings.try_upgrade() {
error!(
"Your settings are out of date and require manual intervention. Your version: {old_version}, latest: {}. See {} for instructions.",
"Your settings are out of date and require manual intervention: {msg}. Your version: {old_version}, latest: {}. See {} for instructions.",
Version::latest(),
env!("CARGO_PKG_REPOSITORY"),
);
Expand Down
4 changes: 2 additions & 2 deletions web/src/forms/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -280,9 +280,9 @@ pub fn import_export_modal() -> Html {
Ok(mut settings) => {
let old_version = settings.version.clone();
import_state.set(Some(
if let Err(()) = settings.try_upgrade() {
if let Err(msg) = settings.try_upgrade() {
Err(format!(
"Your imported settings are out of date and require manual intervention. \
"Your imported settings are out of date and require manual intervention: {msg}. \
Your version: {old_version}, latest: {}. \
See {} for instructions.",
Version::latest(),
Expand Down

0 comments on commit 32232cf

Please sign in to comment.