aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bot/cogs/filtering.py10
-rw-r--r--bot/constants.py3
-rw-r--r--config-default.yml3
3 files changed, 5 insertions, 11 deletions
diff --git a/bot/cogs/filtering.py b/bot/cogs/filtering.py
index 701798d18..d5f19a7cc 100644
--- a/bot/cogs/filtering.py
+++ b/bot/cogs/filtering.py
@@ -74,15 +74,11 @@ class Filtering:
"enabled": Filter.watch_words,
"function": self._has_watchlist_words,
"type": "watchlist",
- "user_notification": False, # Hardcode intentional for watchlist filter type
- "notification_msg": ""
},
"watch_tokens": {
"enabled": Filter.watch_tokens,
"function": self._has_watchlist_tokens,
"type": "watchlist",
- "user_notification": False, # Hardcode intentional, already in token remover cog
- "notification_msg": ""
},
}
@@ -161,9 +157,9 @@ class Filtering:
if _filter["type"] == "filter":
await msg.delete()
- # Notify the user if the filter specifies
- if _filter["user_notification"]:
- await self.notify_member(msg.author, _filter["notification_msg"], msg.channel)
+ # Notify the user if the filter specifies
+ if _filter["user_notification"]:
+ await self.notify_member(msg.author, _filter["notification_msg"], msg.channel)
break # We don't want multiple filters to trigger
diff --git a/bot/constants.py b/bot/constants.py
index 7014a73b3..bbe6c1604 100644
--- a/bot/constants.py
+++ b/bot/constants.py
@@ -204,11 +204,10 @@ class Filter(metaclass=YAMLGetter):
watch_words: bool
watch_tokens: bool
+ # Notifications are not expected for "watchlist" type filters
notify_user_zalgo: bool
notify_user_invites: bool
notify_user_domains: bool
- # Words watch intentionally ignored since it's a watchlist
- # Token notification intentionally ignored, notification is handled by the token remover cog
ping_everyone: bool
guild_invite_whitelist: List[int]
diff --git a/config-default.yml b/config-default.yml
index f8d8f0c26..ad87e44ac 100644
--- a/config-default.yml
+++ b/config-default.yml
@@ -141,11 +141,10 @@ filter:
watch_tokens: true
# Notify user on filter?
+ # Notifications are not expected for "watchlist" type filters
notify_user_zalgo: false
notify_user_invites: true
notify_user_domains: false
- # Words watch intentionally ignored since it's a watchlist
- # Token notification intentionally ignored, notification is handled by the token remover cog
# Filter configuration
ping_everyone: true # Ping @everyone when we send a mod-alert?