diff options
author | Erik Johnston <erik@matrix.org> | 2016-01-18 14:39:43 +0000 |
---|---|---|
committer | Erik Johnston <erik@matrix.org> | 2016-01-18 14:50:17 +0000 |
commit | 0e39dcd1352bcab53908fca574cae43a89e407f0 (patch) | |
tree | f85f9babf3aaecce2868c17779ec8f439ec25a30 /synapse/rest/client | |
parent | Don't edit ruleset (diff) | |
download | synapse-0e39dcd1352bcab53908fca574cae43a89e407f0.tar.xz |
Remove internal ids
Diffstat (limited to 'synapse/rest/client')
-rw-r--r-- | synapse/rest/client/v1/push_rule.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/synapse/rest/client/v1/push_rule.py b/synapse/rest/client/v1/push_rule.py index 0cbd9fe08a..b176efd8a8 100644 --- a/synapse/rest/client/v1/push_rule.py +++ b/synapse/rest/client/v1/push_rule.py @@ -140,6 +140,10 @@ class PushRuleRestServlet(ClientV1RestServlet): template_name = _priority_class_to_template_name(r['priority_class']) + # Remove internal stuff. + for c in r["conditions"]: + c.pop("_id", None) + if r['priority_class'] > PRIORITY_CLASS_MAP['override']: # per-device rule profile_tag = _profile_tag_from_conditions(r["conditions"]) |