From b055a0d4e151263951268d4241db7fb1c183b2c2 Mon Sep 17 00:00:00 2001 From: Zefanja Jobse Date: Sat, 17 Feb 2024 12:11:39 +0100 Subject: [PATCH] remove random object creation --- src/main.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main.rs b/src/main.rs index 62ddd7a..088d06c 100644 --- a/src/main.rs +++ b/src/main.rs @@ -153,9 +153,9 @@ impl EventHandler for Handler { } } -async fn get(game: &String) -> Result { +async fn get(game: &str) -> Result { let client = reqwest::Client::new(); - let url = match game.as_str() { + let url = match game { "bfv" => "https://marne.io/api/v/srvlst/", _ => "https://marne.io/api/srvlst/", };