0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2025-02-18 09:40:12 +01:00

modules/client/sync/rooms/timeline: Consider all events for exposure depth.

This commit is contained in:
Jason Volk 2019-06-06 01:09:57 -07:00
parent 6d429d5cc4
commit 25442bdff2

View file

@ -107,19 +107,8 @@ ircd::m::sync::room_timeline_linear(data &data)
return _room_timeline_linear_command(data);
if(int64_t(exposure_depth) > -1)
{
const bool belated
{
// Don't apply this condition to state events for now
!defined(json::get<"state_key"_>(*data.event)) &&
// Check if the depth is too far in the past relative to the room head
json::get<"depth"_>(*data.event) + int64_t(exposure_depth) < data.room_depth
};
if(belated)
if(json::get<"depth"_>(*data.event) + int64_t(exposure_depth) < data.room_depth)
return false;
}
json::stack::object membership_
{