fix for stage channels
This commit is contained in:
parent
5dc1521181
commit
00565690bc
2
Cargo.lock
generated
2
Cargo.lock
generated
@ -1837,7 +1837,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "soundfx-rs"
|
name = "soundfx-rs"
|
||||||
version = "1.3.0"
|
version = "1.3.1"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"dashmap",
|
"dashmap",
|
||||||
"dotenv",
|
"dotenv",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "soundfx-rs"
|
name = "soundfx-rs"
|
||||||
version = "1.3.0"
|
version = "1.3.1"
|
||||||
authors = ["jellywx <judesouthworth@pm.me>"]
|
authors = ["jellywx <judesouthworth@pm.me>"]
|
||||||
edition = "2018"
|
edition = "2018"
|
||||||
|
|
||||||
|
@ -21,6 +21,7 @@ use serenity::{
|
|||||||
client::{bridge::gateway::GatewayIntents, Client, Context},
|
client::{bridge::gateway::GatewayIntents, Client, Context},
|
||||||
http::Http,
|
http::Http,
|
||||||
model::{
|
model::{
|
||||||
|
channel::Channel,
|
||||||
guild::Guild,
|
guild::Guild,
|
||||||
id::{ChannelId, GuildId, UserId},
|
id::{ChannelId, GuildId, UserId},
|
||||||
},
|
},
|
||||||
@ -137,6 +138,12 @@ async fn join_channel(
|
|||||||
let _ = call.lock().await.deafen(true).await;
|
let _ = call.lock().await.deafen(true).await;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if let Some(Channel::Guild(channel)) = channel_id.to_channel_cached(&ctx).await {
|
||||||
|
channel
|
||||||
|
.edit_voice_state(&ctx, ctx.cache.current_user().await, |v| v.suppress(false))
|
||||||
|
.await;
|
||||||
|
}
|
||||||
|
|
||||||
(call, res)
|
(call, res)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user