feat(automod): add affects_self option for rules

This commit is contained in:
Dragory 2021-10-17 08:15:30 +03:00
parent 1f4f27c26a
commit 151a5df4af
No known key found for this signature in database
GPG key ID: 5F387BA66DF8AAC1
3 changed files with 6 additions and 5 deletions

View file

@ -81,6 +81,10 @@ const configPreprocessor: ConfigPreprocessorFn<AutomodPluginType> = (options) =>
rule["affects_bots"] = false;
}
if (rule["affects_self"] == null) {
rule["affects_self"] = false;
}
// Loop through the rule's triggers
if (rule["triggers"]) {
for (const triggerObj of rule["triggers"]) {