diff options
author | Eric Eastwood <erice@element.io> | 2022-05-10 23:39:14 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-10 23:39:14 -0500 |
commit | 84facf769eb79112be5f21942c18047b2b85f0bd (patch) | |
tree | 72713cc121fca5c81ad6b763e8727e55d0a444c2 /changelog.d | |
parent | Refactor `EventContext` (#12689) (diff) | |
download | synapse-84facf769eb79112be5f21942c18047b2b85f0bd.tar.xz |
Fix `/messages` throwing a 500 when querying for non-existent room (#12683)
Fix https://github.com/matrix-org/synapse/issues/12678 Complement test added: https://github.com/matrix-org/complement/pull/369 **Before:** 500 internal server error **After:** According to the [spec](https://spec.matrix.org/latest/client-server-api/#get_matrixclientv3roomsroomidmessages), calling `/messages` against a non-existent `room_id` should throw a 403 forbidden (since you're not part of the room). This also matches the behavior before https://github.com/matrix-org/synapse/pull/12370 which regressed Synapse to the 500 behavior. ```json { "errcode": "M_FORBIDDEN", "error": "User @test:my.synapse.server not in room !dne:my.synapse.server, and room previews are disabled" } ```
Diffstat (limited to 'changelog.d')
-rw-r--r-- | changelog.d/12683.bugfix | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/changelog.d/12683.bugfix b/changelog.d/12683.bugfix new file mode 100644 index 0000000000..2ce84a223a --- /dev/null +++ b/changelog.d/12683.bugfix @@ -0,0 +1 @@ +Fix a bug introduced in Synapse 1.57.0 where `/messages` would throw a 500 error when querying for a non-existent room. |