mirror of
https://github.com/matrix-construct/construct
synced 2024-12-26 15:33:54 +01:00
modules/client/rooms/members: Add prefetch iterations.
This commit is contained in:
parent
24a27f4a20
commit
3d445fd26c
1 changed files with 17 additions and 0 deletions
|
@ -99,6 +99,16 @@ get__members(client &client,
|
|||
room
|
||||
};
|
||||
|
||||
members.for_each(membership, [¬_membership]
|
||||
(const m::user::id &member, const m::event::idx &event_idx)
|
||||
{
|
||||
if(m::room::members::membership(event_idx, not_membership))
|
||||
return true;
|
||||
|
||||
m::prefetch(event_idx);
|
||||
return true;
|
||||
});
|
||||
|
||||
members.for_each(membership, [&request, &chunk, ¬_membership]
|
||||
(const m::user::id &member, const m::event::idx &event_idx)
|
||||
{
|
||||
|
@ -169,6 +179,13 @@ get__joined_members(client &client,
|
|||
room
|
||||
};
|
||||
|
||||
members.for_each("join", []
|
||||
(const m::user::id &user_id, const m::event::idx &event_idx)
|
||||
{
|
||||
m::prefetch(event_idx);
|
||||
return true;
|
||||
});
|
||||
|
||||
members.for_each("join", [&joined, &room]
|
||||
(const m::user::id &user_id, const m::event::idx &event_idx)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue