mirror of
https://github.com/arthur-pbty/shadowbot.git
synced 2026-06-16 23:57:56 +02:00
feat: restrict commands from being used in DMs
- Added `allow_in_dm: false` to various moderation, utility, and role management commands to prevent their usage in direct messages. - Updated the message event handler to check for the `allow_in_dm` flag and respond appropriately when a DM command is attempted.
This commit is contained in:
@@ -70,6 +70,7 @@ impl crate::commands::command_contract::CommandSpec for DiscussionCommand {
|
||||
description: "Envoie un message de discussion sur un serveur cible.",
|
||||
examples: &["+discussion", "+dn", "+help discussion"],
|
||||
default_aliases: &["dsc"],
|
||||
allow_in_dm: false,
|
||||
default_permission: 8,
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user