Skip to content

Commit 341d956

Browse files
authored
Default to public join rule in remote summary (element-hq#18493)
See: element-hq#18358 (comment)
1 parent 6521406 commit 341d956

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

changelog.d/18493.bugfix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fixed room summary API incorrectly returning that a room is private in the room summary response when the join rule is omitted by the remote server. Contributed by @nexy7574.

synapse/handlers/room_summary.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -701,7 +701,7 @@ async def _is_remote_room_accessible(
701701
# The API doesn't return the room version so assume that a
702702
# join rule of knock is valid.
703703
if (
704-
room.get("join_rule")
704+
room.get("join_rule", JoinRules.PUBLIC)
705705
in (JoinRules.PUBLIC, JoinRules.KNOCK, JoinRules.KNOCK_RESTRICTED)
706706
or room.get("world_readable") is True
707707
):

0 commit comments

Comments
 (0)