mirror of
https://github.com/arthur-pbty/shadowbot.git
synced 2026-06-06 06:10:44 +02:00
feat: ajout des commandes rolemenu et slowmode avec gestion des interactions
This commit is contained in:
@@ -2,7 +2,8 @@ use serenity::model::prelude::*;
|
||||
use serenity::prelude::*;
|
||||
|
||||
use crate::commands::{
|
||||
advanced_tools, boostembed, help, helpsetting, mp, perms_service, suggestion, tempvoc, ticket,
|
||||
advanced_tools, boostembed, help, helpsetting, mp, perms_service, rolemenu, suggestion,
|
||||
tempvoc, ticket,
|
||||
};
|
||||
|
||||
pub async fn handle_interaction_create(ctx: &Context, interaction: &Interaction) {
|
||||
@@ -29,6 +30,10 @@ pub async fn handle_interaction_create(ctx: &Context, interaction: &Interaction)
|
||||
return;
|
||||
}
|
||||
|
||||
if rolemenu::handle_component_interaction(ctx, component).await {
|
||||
return;
|
||||
}
|
||||
|
||||
if help::handle_help_component(ctx, component).await {
|
||||
return;
|
||||
}
|
||||
@@ -66,6 +71,10 @@ pub async fn handle_interaction_create(ctx: &Context, interaction: &Interaction)
|
||||
return;
|
||||
}
|
||||
|
||||
if rolemenu::handle_modal_interaction(ctx, modal).await {
|
||||
return;
|
||||
}
|
||||
|
||||
let _ = advanced_tools::handle_modal_interaction(ctx, modal).await;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user