summary refs log tree commit diff
path: root/synapse/events/utils.py
diff options
context:
space:
mode:
authorPatrick Cloke <clokep@users.noreply.github.com>2021-09-30 11:13:59 -0400
committerGitHub <noreply@github.com>2021-09-30 11:13:59 -0400
commitd1bf5f7c9d669fcf60aadc2c6527447adef2c43c (patch)
treef6d7542295976dfab5be1c7759b7a8b917eefe34 /synapse/events/utils.py
parentFix errors in Synapse logs from unit tests. (#10939) (diff)
downloadsynapse-d1bf5f7c9d669fcf60aadc2c6527447adef2c43c.tar.xz
Strip "join_authorised_via_users_server" from join events which do not need it. (#10933)
This fixes a "Event not signed by authorising server" error when
transition room member from join -> join, e.g. when updating a
display name or avatar URL for restricted rooms.
Diffstat (limited to 'synapse/events/utils.py')
-rw-r--r--synapse/events/utils.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/events/utils.py b/synapse/events/utils.py
index a13fb0148f..520edbbf61 100644
--- a/synapse/events/utils.py
+++ b/synapse/events/utils.py
@@ -105,7 +105,7 @@ def prune_event_dict(room_version: RoomVersion, event_dict: dict) -> dict:
     if event_type == EventTypes.Member:
         add_fields("membership")
         if room_version.msc3375_redaction_rules:
-            add_fields("join_authorised_via_users_server")
+            add_fields(EventContentFields.AUTHORISING_USER)
     elif event_type == EventTypes.Create:
         # MSC2176 rules state that create events cannot be redacted.
         if room_version.msc2176_redaction_rules: