feat: add thread_create_spam automod trigger (#273)
This commit is contained in:
parent
f9c0e661af
commit
6709115166
4 changed files with 63 additions and 0 deletions
|
@ -1,4 +1,5 @@
|
|||
import { typedGuildEventListener } from "knub";
|
||||
import { RecentActionType } from "../constants";
|
||||
import { runAutomod } from "../functions/runAutomod";
|
||||
import { AutomodContext, AutomodPluginType } from "../types";
|
||||
|
||||
|
@ -19,6 +20,13 @@ export const RunAutomodOnThreadCreate = typedGuildEventListener<AutomodPluginTyp
|
|||
};
|
||||
|
||||
pluginData.state.queue.add(() => {
|
||||
pluginData.state.recentActions.push({
|
||||
type: RecentActionType.ThreadCreate,
|
||||
context,
|
||||
count: 1,
|
||||
identifier: null,
|
||||
});
|
||||
|
||||
runAutomod(pluginData, context);
|
||||
});
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue