mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-03-16 22:21:51 +00:00
Fix various automod actions not working for 'other' type matches
This commit is contained in:
parent
84135b201b
commit
84ed1405f0
1 changed files with 4 additions and 4 deletions
|
@ -953,7 +953,7 @@ export class AutomodPlugin extends ZeppelinPlugin<TConfigSchema, ICustomOverride
|
||||||
};
|
};
|
||||||
|
|
||||||
let membersToWarn = [];
|
let membersToWarn = [];
|
||||||
if (matchResult.type === "message" || matchResult.type === "embed") {
|
if (matchResult.type === "message" || matchResult.type === "embed" || matchResult.type === "other") {
|
||||||
membersToWarn = [await this.getMember(matchResult.userId)];
|
membersToWarn = [await this.getMember(matchResult.userId)];
|
||||||
} else if (matchResult.type === "textspam" || matchResult.type === "otherspam") {
|
} else if (matchResult.type === "textspam" || matchResult.type === "otherspam") {
|
||||||
for (const id of spamUserIdsToAction) {
|
for (const id of spamUserIdsToAction) {
|
||||||
|
@ -979,7 +979,7 @@ export class AutomodPlugin extends ZeppelinPlugin<TConfigSchema, ICustomOverride
|
||||||
};
|
};
|
||||||
|
|
||||||
let userIdsToMute = [];
|
let userIdsToMute = [];
|
||||||
if (matchResult.type === "message" || matchResult.type === "embed") {
|
if (matchResult.type === "message" || matchResult.type === "embed" || matchResult.type === "other") {
|
||||||
userIdsToMute = [matchResult.userId];
|
userIdsToMute = [matchResult.userId];
|
||||||
} else if (matchResult.type === "textspam" || matchResult.type === "otherspam") {
|
} else if (matchResult.type === "textspam" || matchResult.type === "otherspam") {
|
||||||
userIdsToMute.push(...spamUserIdsToAction);
|
userIdsToMute.push(...spamUserIdsToAction);
|
||||||
|
@ -1002,7 +1002,7 @@ export class AutomodPlugin extends ZeppelinPlugin<TConfigSchema, ICustomOverride
|
||||||
};
|
};
|
||||||
|
|
||||||
let membersToKick = [];
|
let membersToKick = [];
|
||||||
if (matchResult.type === "message" || matchResult.type === "embed") {
|
if (matchResult.type === "message" || matchResult.type === "embed" || matchResult.type === "other") {
|
||||||
membersToKick = [await this.getMember(matchResult.userId)];
|
membersToKick = [await this.getMember(matchResult.userId)];
|
||||||
} else if (matchResult.type === "textspam" || matchResult.type === "otherspam") {
|
} else if (matchResult.type === "textspam" || matchResult.type === "otherspam") {
|
||||||
for (const id of spamUserIdsToAction) {
|
for (const id of spamUserIdsToAction) {
|
||||||
|
@ -1027,7 +1027,7 @@ export class AutomodPlugin extends ZeppelinPlugin<TConfigSchema, ICustomOverride
|
||||||
};
|
};
|
||||||
|
|
||||||
let userIdsToBan = [];
|
let userIdsToBan = [];
|
||||||
if (matchResult.type === "message" || matchResult.type === "embed") {
|
if (matchResult.type === "message" || matchResult.type === "embed" || matchResult.type === "other") {
|
||||||
userIdsToBan = [matchResult.userId];
|
userIdsToBan = [matchResult.userId];
|
||||||
} else if (matchResult.type === "textspam" || matchResult.type === "otherspam") {
|
} else if (matchResult.type === "textspam" || matchResult.type === "otherspam") {
|
||||||
userIdsToBan.push(...spamUserIdsToAction);
|
userIdsToBan.push(...spamUserIdsToAction);
|
||||||
|
|
Loading…
Add table
Reference in a new issue