diff --git a/crates/flycheck/src/lib.rs b/crates/flycheck/src/lib.rs index 1641f744cd3..d34c9e14722 100644 --- a/crates/flycheck/src/lib.rs +++ b/crates/flycheck/src/lib.rs @@ -326,13 +326,13 @@ fn run(self, command: Command) -> io::Result<()> { ); match output { Ok(_) if read_at_least_one_message => Ok(()), - Ok(output) if output.status.success() => { + Ok(output) if output.status.success() => Ok(()), + Ok(output) => { Err(io::Error::new(io::ErrorKind::Other, format!( "Cargo watcher failed, the command produced no valid metadata (exit code: {:?})", output.status ))) } - Ok(_) => Err(io::Error::new(io::ErrorKind::Other, error)), Err(e) => Err(e), } }