Fix compilation error and remaining test.
Ref. for compilation error: https://github.com/rust-lang/rust/issues/64552master
parent
5bd3c49afc
commit
733689870e
|
@ -1284,11 +1284,13 @@ impl BaseClient {
|
||||||
match &mut *olm {
|
match &mut *olm {
|
||||||
Some(o) => {
|
Some(o) => {
|
||||||
let room = room.write().await;
|
let room = room.write().await;
|
||||||
let members = room
|
|
||||||
.joined_members
|
// XXX: We construct members in a slightly roundabout way instead of chaining the
|
||||||
.keys()
|
// iterators directly because of https://github.com/rust-lang/rust/issues/64552
|
||||||
.chain(room.invited_members.keys());
|
let joined_members = room.joined_members.keys();
|
||||||
Ok(o.share_group_session(room_id, members).await?)
|
let invited_members = room.joined_members.keys();
|
||||||
|
let members: Vec<&UserId> = joined_members.chain(invited_members).collect();
|
||||||
|
Ok(o.share_group_session(room_id, members.into_iter()).await?)
|
||||||
}
|
}
|
||||||
None => panic!("Olm machine wasn't started"),
|
None => panic!("Olm machine wasn't started"),
|
||||||
}
|
}
|
||||||
|
|
|
@ -93,7 +93,7 @@ pub enum CustomOrRawEvent<'c> {
|
||||||
/// {
|
/// {
|
||||||
/// let name = {
|
/// let name = {
|
||||||
/// let room = room.read().await;
|
/// let room = room.read().await;
|
||||||
/// let member = room.members.get(&sender).unwrap();
|
/// let member = room.joined_members.get(&sender).unwrap();
|
||||||
/// member
|
/// member
|
||||||
/// .display_name
|
/// .display_name
|
||||||
/// .as_ref()
|
/// .as_ref()
|
||||||
|
|
Loading…
Reference in New Issue