lock the getter instead ??? c/o M

This commit is contained in:
Jacob Taylor 2025-06-18 16:57:19 -07:00
commit d0aa9eade4
2 changed files with 2 additions and 1 deletions

View file

@ -149,7 +149,7 @@ where
let extremities: Vec<_> = self let extremities: Vec<_> = self
.services .services
.state .state
.get_forward_extremities(room_id) .get_forward_extremities(room_id, &state_lock)
.map(ToOwned::to_owned) .map(ToOwned::to_owned)
.ready_filter(|event_id| { .ready_filter(|event_id| {
// Remove any that are referenced by this incoming event's prev_events // Remove any that are referenced by this incoming event's prev_events

View file

@ -388,6 +388,7 @@ impl Service {
pub fn get_forward_extremities<'a>( pub fn get_forward_extremities<'a>(
&'a self, &'a self,
room_id: &'a RoomId, room_id: &'a RoomId,
_state_lock: &'a RoomMutexGuard,
) -> impl Stream<Item = &EventId> + Send + '_ { ) -> impl Stream<Item = &EventId> + Send + '_ {
let prefix = (room_id, Interfix); let prefix = (room_id, Interfix);