summary refs log tree commit diff
diff options
context:
space:
mode:
authornexy7574 <me@nexy7574.co.uk>2025-06-09 11:59:49 +0100
committerGitHub <noreply@github.com>2025-06-09 10:59:49 +0000
commit341d956ee643567ab3a53f5626b38ace4826bf67 (patch)
treebdba08d82ef5f54e7eb6a4b48a458e51219ca9d8
parentMigrate to assertEqual (#18488) (diff)
downloadsynapse-341d956ee643567ab3a53f5626b38ace4826bf67.tar.xz
Default to `public` join rule in remote summary (#18493)
See: https://github.com/element-hq/synapse/issues/18358#issuecomment-2866119550
-rw-r--r--changelog.d/18493.bugfix1
-rw-r--r--synapse/handlers/room_summary.py2
2 files changed, 2 insertions, 1 deletions
diff --git a/changelog.d/18493.bugfix b/changelog.d/18493.bugfix
new file mode 100644

index 0000000000..a4fab75e69 --- /dev/null +++ b/changelog.d/18493.bugfix
@@ -0,0 +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. diff --git a/synapse/handlers/room_summary.py b/synapse/handlers/room_summary.py
index 64f5bea014..91b131d09b 100644 --- a/synapse/handlers/room_summary.py +++ b/synapse/handlers/room_summary.py
@@ -701,7 +701,7 @@ class RoomSummaryHandler: # The API doesn't return the room version so assume that a # join rule of knock is valid. if ( - room.get("join_rule") + room.get("join_rule", JoinRules.PUBLIC) in (JoinRules.PUBLIC, JoinRules.KNOCK, JoinRules.KNOCK_RESTRICTED) or room.get("world_readable") is True ):