Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Commit 6c1c863

Browse files
committed
Fix it for knocks too while we're here
1 parent 971adec commit 6c1c863

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

changelog.d/10223.bugfix

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Fix a long-standing bug which meant that invite rejections were not sent out over federation in a timely manner.
1+
Fix a long-standing bug which meant that invite rejections and knocks were not sent out over federation in a timely manner.

synapse/handlers/federation.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2091,6 +2091,13 @@ async def on_send_knock_request(
20912091

20922092
event.internal_metadata.outlier = False
20932093

2094+
# Send this event on behalf of the other server.
2095+
#
2096+
# The remote server isn't a full participant in the room at this point, so
2097+
# may not have an up-to-date list of the other homeservers participating in
2098+
# the room, so we send it on their behalf.
2099+
event.internal_metadata.send_on_behalf_of = origin
2100+
20942101
context = await self.state_handler.compute_event_context(event)
20952102

20962103
event_allowed = await self.third_party_event_rules.check_event_allowed(

0 commit comments

Comments
 (0)