Cargo fmt
This commit is contained in:
parent
d42b0ec6b3
commit
acf059aa1a
|
@ -243,7 +243,10 @@ impl Rn2903 {
|
|||
fn transact_expecting(&mut self, command: &[u8], expectation: &[u8]) -> Result<()> {
|
||||
let bytes = self.transact(command)?;
|
||||
if bytes != expectation {
|
||||
Err(Error::bad_response(bytes_to_string(expectation), bytes_to_string(&bytes)))
|
||||
Err(Error::bad_response(
|
||||
bytes_to_string(expectation),
|
||||
bytes_to_string(&bytes),
|
||||
))
|
||||
} else {
|
||||
Ok(())
|
||||
}
|
||||
|
@ -303,7 +306,6 @@ impl Rn2903 {
|
|||
|
||||
Ok(vec)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/// # System API Functions
|
||||
|
@ -353,7 +355,7 @@ impl Rn2903 {
|
|||
let val = bytes_to_string(&self.transact(b"mac pause")?);
|
||||
let ms: u32 = match val.parse() {
|
||||
Ok(v) => v,
|
||||
Err(_) => return Err(Error::bad_response("<integer>", val))
|
||||
Err(_) => return Err(Error::bad_response("<integer>", val)),
|
||||
};
|
||||
if ms == 0 {
|
||||
Err(Error::CannotPause)
|
||||
|
|
Loading…
Reference in New Issue