moved message structs and ran cargo fmt

This commit is contained in:
Anish Nayak
2025-08-12 19:59:53 +01:00
parent 14e6d59ddd
commit 540db21c45
11 changed files with 211 additions and 171 deletions
@@ -1,12 +1,15 @@
use std::sync::Arc;
use scc::HashMap;
use twilight_model::{
application::interaction::InteractionData, application::command::CommandType, gateway::payload::incoming::InteractionCreate,
};
use crate::framework::{
interactions::{InteractionError, context::InteractionContext, message_command::MessageCommand},
interactions::{
InteractionError, context::InteractionContext, message_command::MessageCommand,
},
runtime::Runtime,
};
use scc::HashMap;
use std::sync::Arc;
use twilight_model::{
application::command::CommandType, application::interaction::InteractionData,
gateway::payload::incoming::InteractionCreate,
};
#[derive(Default)]
pub struct MessageCommandRegistry<T> {
@@ -53,7 +56,11 @@ where
if let Some(target_id) = data.target_id {
command
.execute(
InteractionContext::new(event.clone(), rt.clone(), prefix.to_string()),
InteractionContext::new(
event.clone(),
rt.clone(),
prefix.to_string(),
),
target_id.get(),
)
.await