diff options
| author | Eskil Queseth <eskilq@kth.se> | 2021-06-14 13:44:08 +0200 |
|---|---|---|
| committer | Eskil Queseth <eskilq@kth.se> | 2021-06-14 13:44:08 +0200 |
| commit | f24f23faa240053b7ac8f65b69ff8d1ae0ad3ea1 (patch) | |
| tree | b3c6406951d9e09836336290b63ceaa9d7efc04b /mumd/src/main.rs | |
| parent | f4beab72096060f513d6b22c0ee891688595dcbd (diff) | |
| download | mum-f24f23faa240053b7ac8f65b69ff8d1ae0ad3ea1.tar.gz | |
clippy
Diffstat (limited to 'mumd/src/main.rs')
| -rw-r--r-- | mumd/src/main.rs | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/mumd/src/main.rs b/mumd/src/main.rs index 8d278c0..6a70586 100644 --- a/mumd/src/main.rs +++ b/mumd/src/main.rs @@ -37,9 +37,7 @@ use tokio_util::codec::{FramedRead, FramedWrite, LengthDelimitedCodec}; #[tokio::main] async fn main() { - if std::env::args() - .find(|s| s.as_str() == "--version") - .is_some() + if std::env::args().any(|s| s.as_str() == "--version") { println!("mumd {}", env!("VERSION")); return; @@ -94,12 +92,9 @@ async fn main() { _ = receive_commands(command_sender).fuse() => Ok(()), }; - match run { - Err(e) => { - error!("mumd: {}", e); - std::process::exit(1); - } - _ => {} + if let Err(e) = run { + error!("mumd: {}", e); + std::process::exit(1); } } |
