mirror of
https://forgejo.ellis.link/continuwuation/continuwuity.git
synced 2025-07-05 19:55:49 +02:00
lock the getter instead ??? c/o M
This commit is contained in:
parent
2b61f91f1f
commit
9e8c193840
3 changed files with 3 additions and 2 deletions
|
@ -149,7 +149,7 @@ where
|
|||
let extremities: Vec<_> = self
|
||||
.services
|
||||
.state
|
||||
.get_forward_extremities(room_id)
|
||||
.get_forward_extremities(room_id, &state_lock)
|
||||
.map(ToOwned::to_owned)
|
||||
.ready_filter(|event_id| {
|
||||
// Remove any that are referenced by this incoming event's prev_events
|
||||
|
|
|
@ -388,6 +388,7 @@ impl Service {
|
|||
pub fn get_forward_extremities<'a>(
|
||||
&'a self,
|
||||
room_id: &'a RoomId,
|
||||
_state_lock: &'a RoomMutexGuard,
|
||||
) -> impl Stream<Item = &EventId> + Send + '_ {
|
||||
let prefix = (room_id, Interfix);
|
||||
|
||||
|
|
|
@ -42,7 +42,7 @@ pub async fn create_hash_and_sign_event(
|
|||
let prev_events: Vec<OwnedEventId> = self
|
||||
.services
|
||||
.state
|
||||
.get_forward_extremities(room_id)
|
||||
.get_forward_extremities(room_id, _mutex_lock)
|
||||
.take(20)
|
||||
.map(Into::into)
|
||||
.collect()
|
||||
|
|
Loading…
Add table
Reference in a new issue