From 1da12cab4876e7a1c0f4e9cd8374c4c12d230f7b Mon Sep 17 00:00:00 2001 From: Evie Viau Date: Sat, 19 Feb 2022 20:33:10 -0500 Subject: [PATCH] Remove some debugging println! macros and reorder InfoData --- src/infoops.rs | 6 +++--- src/main.rs | 1 - 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/infoops.rs b/src/infoops.rs index 83d2c57..f56af69 100644 --- a/src/infoops.rs +++ b/src/infoops.rs @@ -80,6 +80,9 @@ pub struct VST_CREATE { #[derive(Deserialize, Serialize, Debug)] #[serde(untagged)] pub enum InfoData { + /// Sent by the client to create a voice state. + VST_CREATE(VST_CREATE), + /// Request a channel to be created inside the voice server. /// /// The Server MUST reply back with a CHANNEL_ASSIGN when resources are @@ -108,9 +111,6 @@ pub enum InfoData { guild_id: Option }, - /// Sent by the client to create a voice state. - VST_CREATE(VST_CREATE), - /// Sent by the server to indicate the success of a VST_CREATE. VST_DONE { /// User ID diff --git a/src/main.rs b/src/main.rs index d7abff3..215adaf 100644 --- a/src/main.rs +++ b/src/main.rs @@ -220,7 +220,6 @@ async fn handle_conn(peer: SocketAddr, stream: TcpStream, redis_client: Client, }, InfoType::CHANNEL_DESTROY => todo!(), InfoType::VST_CREATE => { - println!("{:?} {:?}", &info.0, &info.1); if let InfoData::VST_CREATE(dn) = info.1 { let guild_id = dn.clone().guild_id.unwrap_or("dm".to_string()); println!("Creating voice state for {} in {}", &dn.channel_id, &guild_id);