From 02f8ac609541a47823bfb8238f600a47e7e4b652 Mon Sep 17 00:00:00 2001 From: Marty Sluijtman Date: Sat, 21 Jun 2025 21:16:26 +0200 Subject: [PATCH] Slight optimisation --- src/main.rs | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/main.rs b/src/main.rs index 574fcda..1fcbfb3 100644 --- a/src/main.rs +++ b/src/main.rs @@ -84,10 +84,7 @@ fn main() { let n = libnotify::Notification::new("Noise", None, None); let cli = Cli::parse(); - let host = match cli.host { - Some(host) => host, - None => String::from("localhost:6600"), - }; + let host = cli.host.unwrap_or("localhost:6600".into()); let mut conn = Client::connect(host).expect("Connection failed");