Skip to content

Commit 3be1686

Browse files
committed
Treat "already banned" as a ban state for the phishing AlertView
1 parent 329528e commit 3be1686

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • bot/exts/filtering/_ui

bot/exts/filtering/_ui/ui.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -616,7 +616,7 @@ class AlertView(discord.ui.View):
616616
def __init__(self, ctx: FilterContext, triggered_filters: dict[FilterList, list[str]] | None = None):
617617
super().__init__(timeout=ALERT_VIEW_TIMEOUT)
618618
self.ctx = ctx
619-
if "banned" in self.ctx.action_descriptions:
619+
if {"banned", "already banned"} & set(self.ctx.action_descriptions):
620620
# If the user has already been banned, do not attempt to add phishing button since the URL or guild invite
621621
# is probably already added as a filter
622622
return

0 commit comments

Comments
 (0)