From 53b54e0f62a20b4f86547c48099c6c92bc51a0a4 Mon Sep 17 00:00:00 2001 From: Jason Volk Date: Mon, 12 Aug 2019 01:21:05 -0700 Subject: [PATCH] modules/client/sync/rooms/state: Fix left rooms members droptimization. --- modules/client/sync/rooms/state.cc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/modules/client/sync/rooms/state.cc b/modules/client/sync/rooms/state.cc index 2d242a6aa..e26d7b6c9 100644 --- a/modules/client/sync/rooms/state.cc +++ b/modules/client/sync/rooms/state.cc @@ -303,9 +303,10 @@ ircd::m::sync::room_state_polylog_events(data &data) // For crazyloading, skip membership events in rooms the user is not // presently joined. - if(!crazyload_historical_members && !data.args->full_state && data.phased) - if(data.membership != "join" && type == "m.room.member") - return true; + if(!crazyload_historical_members) + if(!data.args->full_state && type == "m.room.member") + if(data.membership == "leave" || data.membership == "ban") + return true; this_ctx::interruption_point(); concurrent(event_idx);