From 154572f6be9d082b4030d3a94433e3b717d4d8df Mon Sep 17 00:00:00 2001 From: Yash Karandikar Date: Thu, 28 Jul 2022 11:39:05 -0500 Subject: [PATCH] Fix clippy lints --- src/bot.rs | 2 +- src/database.rs | 2 +- src/main.rs | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/bot.rs b/src/bot.rs index 1a4010a..e51ff2e 100644 --- a/src/bot.rs +++ b/src/bot.rs @@ -116,7 +116,7 @@ impl anyhow::Result<()>> Bot { _cancel_handle: mpsc::Sender<()>, ) { if let Err(e) = self.handle_message_inner(&origin, &author, &content).await { - let _err = (self.sendmsg)(origin.into(), format!("Error: {}", e)); + let _err = (self.sendmsg)(origin, format!("Error: {}", e)); } } } diff --git a/src/database.rs b/src/database.rs index baf3524..24cfade 100644 --- a/src/database.rs +++ b/src/database.rs @@ -88,7 +88,7 @@ impl DbExecutor { tracing::debug!( "task took {}ms", Instant::now().duration_since(before).as_secs_f64() / 1000.0 - ) + ); } } diff --git a/src/main.rs b/src/main.rs index 20ab02a..19552f1 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,4 +1,5 @@ -#![allow(clippy::module_name_repetitions)] +#![warn(clippy::pedantic)] +#![allow(clippy::module_name_repetitions, clippy::too_many_lines)] use fancy_regex::Regex; use std::str::FromStr;