Skip to content

Commit

Permalink
Fix exit case bug
Browse files Browse the repository at this point in the history
  • Loading branch information
Kyle Criddle committed Aug 21, 2021
1 parent 459a216 commit 0712915
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 @@ -68,7 +68,7 @@ fn get_free_space(hdds: &mut Vec<String>, plot_sz: u64) -> Result<&str, Box<dyn
hdds.retain(|path_| path != path_);
hdd_idx = hdd_idx - 1;
}
if hdd_idx == -1 {
if hdd_idx < 0 {
panic!("no plots were available to remove! are we done re-plotting ?!?!?!")
}
Ok(&hdds[hdd_idx as usize])
Expand Down

0 comments on commit 0712915

Please sign in to comment.