From 5a2dc4070c1d14f22a7671c6f82ca2f4578369bd Mon Sep 17 00:00:00 2001 From: Nathan Perry Date: Fri, 16 Aug 2024 06:40:25 -0400 Subject: rework logging to use tracing via grate --- src/commands/meme/invoke.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/commands/meme/invoke.rs') diff --git a/src/commands/meme/invoke.rs b/src/commands/meme/invoke.rs index 1d9040d..37a78f5 100644 --- a/src/commands/meme/invoke.rs +++ b/src/commands/meme/invoke.rs @@ -2,7 +2,7 @@ use diesel::{ result::Error as DieselError, NotFound, }; -use log::info; +use grate::tracing; use crate::{ commands::meme::send_meme, @@ -89,7 +89,7 @@ pub(crate) async fn _meme( }, Err(e) => { return if let Some(NotFound) = e.downcast_ref::() { - info!("requested meme not found in database"); + tracing::info!("requested meme not found in database"); util::reply(ctx, "c'mon baby, guesstimate").await?; Ok(()) @@ -123,7 +123,7 @@ async fn rand_meme(ctx: PoiseContext<'_>, audio_playback: AudioPlayback) -> anyh }, Err(e) => { if let Some(NotFound) = e.downcast_ref::() { - info!("random meme not found"); + tracing::info!("random meme not found"); util::reply(ctx, "i don't know any :(").await?; return Ok(()); @@ -151,7 +151,7 @@ pub async fn rare_meme(ctx: PoiseContext<'_>) -> anyhow::Result<()> { }, Err(e) => { if let Some(NotFound) = e.downcast_ref::() { - info!("rare meme not found"); + tracing::info!("rare meme not found"); util::reply(ctx, "i don't know any :(").await?; return Ok(()); -- cgit v1.3.1