Fixed Begin/End error handling
This commit is contained in:
parent
8aae65e3c6
commit
e63e467f4a
|
@ -85,7 +85,10 @@ pub mod timetracking {
|
|||
let mut gtoth: f64 = 0.0;
|
||||
for (act, tstamps) in start.iter_mut().sorted_by_key(|x| x.0) {
|
||||
let bc: i64 = tstamps.len().try_into().unwrap();
|
||||
let ec: i64 = finish.get(&act.to_string()).expect("Somehow, not a vector!").len().try_into().unwrap();
|
||||
let mut ec: i64 = 0;
|
||||
if finish.contains_key(&act.to_string()) {
|
||||
ec = finish.get(&act.to_string()).expect("Somehow, not a vector!").len().try_into().unwrap();
|
||||
};
|
||||
|
||||
// Debugging
|
||||
// println!("bc: {}, ec: {}", bc, ec);
|
||||
|
|
Loading…
Reference in New Issue