Use tracing instead of println for connection message
This commit is contained in:
parent
dc856ea3fd
commit
32d35a2c02
1 changed files with 4 additions and 3 deletions
|
@ -4,8 +4,6 @@ mod commands;
|
|||
mod personality;
|
||||
mod queue;
|
||||
|
||||
use commands::*;
|
||||
|
||||
use std::{env, sync::Arc};
|
||||
|
||||
use anyhow::Result;
|
||||
|
@ -13,8 +11,11 @@ use parking_lot::Mutex;
|
|||
use poise::serenity_prelude as serenity;
|
||||
use reqwest::Client as HttpClient;
|
||||
use songbird::SerenityInit;
|
||||
use tracing::info;
|
||||
use tracing_subscriber::{fmt, prelude::*, EnvFilter};
|
||||
|
||||
use commands::*;
|
||||
|
||||
pub struct Data {
|
||||
http_client: HttpClient,
|
||||
queue: Arc<Mutex<queue::Queue>>,
|
||||
|
@ -29,7 +30,7 @@ async fn event_event_handler(
|
|||
_user_data: &Data,
|
||||
) -> Result<(), Error> {
|
||||
if let serenity::FullEvent::Ready { data_about_bot } = event {
|
||||
println!("{} is connected!", data_about_bot.user.name)
|
||||
info!("{} is connected!", data_about_bot.user.name)
|
||||
}
|
||||
|
||||
Ok(())
|
||||
|
|
Loading…
Add table
Reference in a new issue