Skip to content

Commit

Permalink
style: change a non-obvious .unwrap to .expect
Browse files Browse the repository at this point in the history
  • Loading branch information
mkforsb committed Feb 16, 2025
1 parent b132965 commit 1196569
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ fn update(model_ptr: AppModelPtr, view: &AsampoView, message: AppMessage) {
return;
}

let old_model = model_ptr.take().unwrap();
let old_model = model_ptr.take().expect("Always a model present at the start of update()");

match update_model(old_model.clone(), message) {
Ok(new_model) => {
Expand Down

0 comments on commit 1196569

Please sign in to comment.