From 37704069f162c381e22abf9c9ae1f857c90ffd8c Mon Sep 17 00:00:00 2001 From: Dragory <2606411+Dragory@users.noreply.github.com> Date: Fri, 17 Apr 2020 23:28:09 +0300 Subject: [PATCH] automod: only match highlighted links in match_links by default --- backend/src/plugins/Automod/Automod.ts | 6 ++++++ backend/src/plugins/Automod/types.ts | 1 + 2 files changed, 7 insertions(+) diff --git a/backend/src/plugins/Automod/Automod.ts b/backend/src/plugins/Automod/Automod.ts index d80144b2..9949cc14 100644 --- a/backend/src/plugins/Automod/Automod.ts +++ b/backend/src/plugins/Automod/Automod.ts @@ -116,6 +116,7 @@ const defaultMatchLinksTrigger: Partial = { match_usernames: false, match_nicknames: false, match_custom_status: false, + only_real_links: true, }; const defaultMatchAttachmentTypeTrigger: Partial = { @@ -456,6 +457,11 @@ export class AutomodPlugin extends ZeppelinPlugin Include diff --git a/backend/src/plugins/Automod/types.ts b/backend/src/plugins/Automod/types.ts index 271ce33b..7a64a90c 100644 --- a/backend/src/plugins/Automod/types.ts +++ b/backend/src/plugins/Automod/types.ts @@ -174,6 +174,7 @@ export const MatchLinksTrigger = t.type({ exclude_words: tNullable(t.array(t.string)), include_regex: tNullable(t.array(TSafeRegex)), exclude_regex: tNullable(t.array(TSafeRegex)), + only_real_links: t.boolean, match_messages: t.boolean, match_embeds: t.boolean, match_visible_names: t.boolean,