mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-05-21 16:55:03 +00:00
Add antiraid commands
This commit is contained in:
parent
19f6e49251
commit
4eda695911
4 changed files with 62 additions and 0 deletions
14
backend/src/plugins/Automod/commands/AntiraidClearCmd.ts
Normal file
14
backend/src/plugins/Automod/commands/AntiraidClearCmd.ts
Normal file
|
@ -0,0 +1,14 @@
|
|||
import { command } from "knub";
|
||||
import { AutomodPluginType } from "../types";
|
||||
import { setAntiraidLevel } from "../functions/setAntiraidLevel";
|
||||
import { sendSuccessMessage } from "../../../pluginUtils";
|
||||
|
||||
export const AntiraidClearCmd = command<AutomodPluginType>()({
|
||||
trigger: ["antiraid clear", "antiraid reset", "antiraid none", "antiraid off"],
|
||||
permission: "can_set_antiraid",
|
||||
|
||||
async run({ pluginData, message }) {
|
||||
await setAntiraidLevel(pluginData, null, message.author);
|
||||
sendSuccessMessage(pluginData, message.channel, "Anti-raid turned **off**");
|
||||
},
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue