diff --git a/src/core/instance/updater.rs b/src/core/instance/updater.rs index f342098..4b23bec 100644 --- a/src/core/instance/updater.rs +++ b/src/core/instance/updater.rs @@ -20,8 +20,6 @@ pub fn updater_thread(operation_rx : Receiver, instance: &Instance) - let mut count = 0; loop { - println!("updater_thread loop beginning: {}", operation_rx.len()); - let mut operation = operation_rx.recv()?; trace!("OPERATION {}", count); diff --git a/src/core/proto/mod.rs b/src/core/proto/mod.rs index 1d4e14a..5a4f08e 100644 --- a/src/core/proto/mod.rs +++ b/src/core/proto/mod.rs @@ -216,16 +216,18 @@ impl MizeMessage { let data = { let mut tmp_val = &CborValue::Null; + let mut found = false; for (key, val) in msg_as_map { if let CborValue::Integer(key_int) = key { // number three indicates the data field let three: Integer = 3.into(); if key_int == &three { tmp_val = val; + found = true; } } } - if tmp_val == &CborValue::Null { + if ! found { return Err(MizeError::new().msg("error getting the data value form a msg")); } tmp_val