Fix: use correct parameter when calling get_local_current_membership_for_user_in_room (#19353)

Co-authored-by: Andrew Morgan <1342360+anoadragon453@users.noreply.github.com>
This commit is contained in:
Lukas Tautz 2026-01-07 19:32:16 +01:00 committed by GitHub
parent cbc5469113
commit 8ff1960878
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 1 deletions

1
changelog.d/19353.bugfix Normal file
View file

@ -0,0 +1 @@
Fix a bug introduced in 1.61.0 where a user's membership in a room was accidentally ignored when considering access to historical state events in rooms with the "shared" history visibility. Contributed by Lukas Tautz.

View file

@ -322,7 +322,7 @@ class MessageHandler:
current_membership,
_,
) = await self.store.get_local_current_membership_for_user_in_room(
user_id, event_id
user_id, room_id
)
return current_membership == Membership.JOIN