diff options
author | Erik Johnston <erik@matrix.org> | 2017-04-26 16:23:30 +0100 |
---|---|---|
committer | Erik Johnston <erik@matrix.org> | 2017-04-26 16:23:30 +0100 |
commit | 1e166470abf9a765eb66f5ea02382143f031e1fe (patch) | |
tree | 506c4fa8463344e1609c429eb84ebac0acd3ccd8 /synapse/events | |
parent | Fix invite state to always include all events (diff) | |
download | synapse-1e166470abf9a765eb66f5ea02382143f031e1fe.tar.xz |
Fix tests
Diffstat (limited to 'synapse/events')
-rw-r--r-- | synapse/events/utils.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/synapse/events/utils.py b/synapse/events/utils.py index 7ca7796558..c42b73d11a 100644 --- a/synapse/events/utils.py +++ b/synapse/events/utils.py @@ -266,6 +266,9 @@ def serialize_event(e, time_now_ms, as_client_event=True, if txn_id is not None: d["unsigned"]["transaction_id"] = txn_id + if not is_invite: + d["unsigned"].pop("invite_room_state", None) + if as_client_event: d = event_format(d) @@ -275,7 +278,4 @@ def serialize_event(e, time_now_ms, as_client_event=True, raise TypeError("only_event_fields must be a list of strings") d = only_fields(d, only_event_fields) - if not is_invite: - d["unsigned"].pop("invite_room_state", None) - return d |