From c60a301874c0444940c8c052a1f0544add44f520 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9e=20Kooi?= Date: Sun, 27 Oct 2024 12:10:07 +0100 Subject: [PATCH] clippy --- src/handlers/emotes.rs | 5 ----- src/main.rs | 2 +- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/src/handlers/emotes.rs b/src/handlers/emotes.rs index b45c079..17bdb95 100644 --- a/src/handlers/emotes.rs +++ b/src/handlers/emotes.rs @@ -1,6 +1,5 @@ use crate::api::neocities; use crate::handler::{Api, ChatCommand, Handler, MessageType}; -use crate::SekshiBot; use indoc::indoc; use rusqlite::{Connection, OptionalExtension as _}; use shorten_url::shorten; @@ -8,10 +7,6 @@ use shorten_url::shorten; #[derive(Debug)] pub struct Emotes; impl Emotes { - pub fn new(_bot: &mut SekshiBot) -> anyhow::Result { - Ok(Self) - } - fn get_emote(&self, db: &Connection, name: &str) -> anyhow::Result> { let url = db .query_row("SELECT url FROM emotes WHERE name = ?", [name], |row| { diff --git a/src/main.rs b/src/main.rs index ab1c8b3..3f96ef1 100644 --- a/src/main.rs +++ b/src/main.rs @@ -89,7 +89,7 @@ fn main() -> Result { }; let metrics_endpoint = args.metrics.as_deref().unwrap_or("0.0.0.0:3003"); - let tx = setup_metrics(&metrics_endpoint)?; + let tx = setup_metrics(metrics_endpoint)?; let result = (|| { let bot = SekshiBot::connect(ConnectionOptions {