Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
synapse
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Maunium
synapse
Commits
7065b75b
Commit
7065b75b
authored
9 years ago
by
David Baker
Browse files
Options
Downloads
Patches
Plain Diff
Don't crash if a user has no push rule enabled entries
parent
52bdd1b8
No related branches found
Branches containing commit
Tags
v1.34.0
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
synapse/push/bulk_push_rule_evaluator.py
+3
-0
3 additions, 0 deletions
synapse/push/bulk_push_rule_evaluator.py
with
3 additions
and
0 deletions
synapse/push/bulk_push_rule_evaluator.py
+
3
−
0
View file @
7065b75b
...
@@ -50,6 +50,9 @@ def _get_rules(room_id, user_ids, store):
...
@@ -50,6 +50,9 @@ def _get_rules(room_id, user_ids, store):
# fetch disabled rules, but this won't account for any server default
# fetch disabled rules, but this won't account for any server default
# rules the user has disabled, so we need to do this too.
# rules the user has disabled, so we need to do this too.
for
uid
in
user_ids
:
for
uid
in
user_ids
:
if
uid
not
in
rules_enabled_by_user
:
continue
user_enabled_map
=
rules_enabled_by_user
[
uid
]
user_enabled_map
=
rules_enabled_by_user
[
uid
]
for
rule
in
rules_by_user
[
uid
]:
for
rule
in
rules_by_user
[
uid
]:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment