chore: move call configuration to after handler instantiation to reduce time between them

This commit is contained in:
2026-05-13 22:25:05 -04:00
parent a64e7190fd
commit 949ce5b38b

View File

@@ -275,14 +275,6 @@ pub async fn handle(state: State, interaction: Interaction) {
.await
.expect("TODO");
let call = state
.songbird
.join(guild_id, voice_channel_id)
.await
.expect("TODO");
tracing::error!(?call, "successfully joined");
let start_instant = Instant::now();
let start_utc = UtcDateTime::now();
@@ -304,6 +296,13 @@ pub async fn handle(state: State, interaction: Interaction) {
user_data_manager: state.user_data_manager,
};
let call = state
.songbird
.join(guild_id, voice_channel_id)
.await
.expect("TODO");
tracing::error!(?call, "successfully joined");
{
let mut call = call.lock().await;