From 065ac97194b7640ca350b4770b404d855bf98b17 Mon Sep 17 00:00:00 2001 From: seth Date: Fri, 7 Apr 2023 20:02:01 -0400 Subject: cargo fmt --- src/utils.rs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'src/utils.rs') diff --git a/src/utils.rs b/src/utils.rs index bb57521..78e02dd 100644 --- a/src/utils.rs +++ b/src/utils.rs @@ -13,9 +13,7 @@ const FILES: Dir = include_dir!("src/include"); */ async fn random_choice(arr: [&str; N]) -> String { let mut rng = rand::thread_rng(); - let resp = arr - .choose(&mut rng) - .expect("couldn't choose random value!"); + let resp = arr.choose(&mut rng).expect("couldn't choose random value!"); resp.to_string() } @@ -25,11 +23,11 @@ async fn random_choice(arr: [&str; N]) -> String { */ pub async fn get_random_response() -> String { - random_choice(RESPONSES).await + random_choice(RESPONSES).await } pub async fn get_random_lore() -> String { - random_choice(LORE).await + random_choice(LORE).await } /* -- cgit v1.2.3