mirror of
https://github.com/arthur-pbty/shadowbot.git
synced 2026-06-05 00:06:23 +02:00
3e69185296
- Implemented `handle_message_update` to log message edits. - Created role event handlers for role creation, update, and deletion. - Added voice state update handling to log channel changes. - Introduced a new `ready_event` handler to restore bot presence and enforce blacklist. - Updated `mod.rs` to include new event modules. - Enhanced `main.rs` for database connection and initialization. - Added comprehensive permission management in `permissions.rs`.
24 lines
907 B
Rust
24 lines
907 B
Rust
use crate::commands::moderation_tools;
|
|
use serenity::model::prelude::*;
|
|
use serenity::prelude::*;
|
|
pub async fn handle_cmute(ctx: &Context, msg: &Message, args: &[&str]) {
|
|
moderation_tools::handle_cmute(ctx, msg, args, false).await;
|
|
}
|
|
pub struct CmuteCommand;
|
|
pub static COMMAND_DESCRIPTOR: CmuteCommand = CmuteCommand;
|
|
impl crate::commands::command_contract::CommandSpec for CmuteCommand {
|
|
fn metadata(&self) -> crate::commands::command_contract::CommandMetadata {
|
|
crate::commands::command_contract::CommandMetadata {
|
|
key: "cmute",
|
|
command: "cmute",
|
|
category: "admin",
|
|
params: "<@membre/ID[,..]> [raison]",
|
|
summary: "Mute salon",
|
|
description: "Mute un membre sur le salon courant.",
|
|
examples: &["+cmute @User"],
|
|
alias_source_key: "cmute",
|
|
default_aliases: &["cm"],
|
|
}
|
|
}
|
|
}
|