mirror of
https://gitlab.com/brutaldon/brutaldon
synced 2025-06-05 21:49:32 +02:00
Fix filters in notifications
This commit is contained in:
@@ -173,7 +173,9 @@ def toot_matches_filters(toot, filters=[]):
|
||||
return filter.phrase
|
||||
phrases = [maybe_rewrite_filter(x) for x in filters]
|
||||
pattern = "|".join(phrases)
|
||||
try:
|
||||
try:
|
||||
if toot.get('type') in ['reblog', 'favourite']:
|
||||
return re.search(pattern, toot.status.spoiler_text + toot.status.content, re.I)
|
||||
return re.search(pattern, toot.spoiler_text + toot.content, re.I)
|
||||
except:
|
||||
return False
|
||||
|
Reference in New Issue
Block a user