Actually act on mark_unread

This commit is contained in:
Brendan Abolivier 2020-06-11 15:30:42 +01:00
parent 9dbd006607
commit ea8f6e611b
No known key found for this signature in database
GPG Key ID: 1E015C145F1916CD

View File

@ -191,9 +191,13 @@ class BulkPushRuleEvaluator(object):
) )
if matches: if matches:
actions = [x for x in rule["actions"] if x != "dont_notify"] actions = [x for x in rule["actions"] if x != "dont_notify"]
if actions and "notify" in actions: if actions:
# Push rules say we should notify the user of this event if (
actions_by_user[uid] = actions "notify" in actions
or "org.matrix.msc2625.mark_unread" in actions
):
# Push rules say we should act on this event.
actions_by_user[uid] = actions
break break
# Mark in the DB staging area the push actions for users who should be # Mark in the DB staging area the push actions for users who should be