diff options
author | Richard van der Hoff <1389908+richvdh@users.noreply.github.com> | 2020-10-16 13:39:46 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-16 13:39:46 +0100 |
commit | da0090fdff65f9f3fecad039f35b8e3615f8d100 (patch) | |
tree | e4ca727b1cb81161e0b0c7292fb7f9688497a03a /synapse/handlers/message.py | |
parent | Merge pull request #8535 from matrix-org/rav/third_party_events_updates (diff) | |
download | synapse-da0090fdff65f9f3fecad039f35b8e3615f8d100.tar.xz |
Fix modifying events in `ThirdPartyRules` modules (#8564)
EventBuilder.build wants auth events these days
Diffstat (limited to 'synapse/handlers/message.py')
-rw-r--r-- | synapse/handlers/message.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/synapse/handlers/message.py b/synapse/handlers/message.py index 7f00805a91..d6855c60ea 100644 --- a/synapse/handlers/message.py +++ b/synapse/handlers/message.py @@ -1364,7 +1364,12 @@ class EventCreationHandler: for k, v in original_event.internal_metadata.get_dict().items(): setattr(builder.internal_metadata, k, v) - event = await builder.build(prev_event_ids=original_event.prev_event_ids()) + # the event type hasn't changed, so there's no point in re-calculating the + # auth events. + event = await builder.build( + prev_event_ids=original_event.prev_event_ids(), + auth_event_ids=original_event.auth_event_ids(), + ) # we rebuild the event context, to be on the safe side. If nothing else, # delta_ids might need an update. |