base: Remove an aditional looping through the joined state events.
This commit is contained in:
parent
c9d38cdedb
commit
c0ff782ea3
1 changed files with 2 additions and 8 deletions
|
@ -732,6 +732,8 @@ impl BaseClient {
|
|||
if self.receive_joined_state_event(&room_id, &e).await {
|
||||
updated = true;
|
||||
}
|
||||
self.emit_state_event(&room_id, &e, RoomStateType::Joined)
|
||||
.await;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -764,14 +766,6 @@ impl BaseClient {
|
|||
.await
|
||||
.set_unread_notice_count(&joined_room.unread_notifications);
|
||||
|
||||
// re looping is not ideal here
|
||||
for event in &mut joined_room.state.events {
|
||||
if let Ok(e) = event.deserialize() {
|
||||
self.emit_state_event(&room_id, &e, RoomStateType::Joined)
|
||||
.await;
|
||||
}
|
||||
}
|
||||
|
||||
for mut event in &mut joined_room.timeline.events {
|
||||
let decrypted_event = {
|
||||
let (decrypt_ev, timeline_update) = self
|
||||
|
|
Loading…
Reference in a new issue