Add member_leave automod trigger
At least i think so - cant test it until knub changes are done
This commit is contained in:
parent
2700f4e389
commit
f9dd82f201
6 changed files with 49 additions and 2 deletions
20
backend/src/plugins/Automod/triggers/memberLeave.ts
Normal file
20
backend/src/plugins/Automod/triggers/memberLeave.ts
Normal file
|
@ -0,0 +1,20 @@
|
|||
import * as t from "io-ts";
|
||||
import { automodTrigger } from "../helpers";
|
||||
|
||||
export const MemberLeaveTrigger = automodTrigger<unknown>()({
|
||||
configType: t.type({}),
|
||||
|
||||
defaultConfig: {},
|
||||
|
||||
async match({ pluginData, context, triggerConfig }) {
|
||||
if (!context.joined || !context.member) {
|
||||
return;
|
||||
}
|
||||
|
||||
return {};
|
||||
},
|
||||
|
||||
renderMatchInformation({ pluginData, contexts, triggerConfig }) {
|
||||
return "";
|
||||
},
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue