mirror of
https://gitlab.com/famedly/conduit.git
synced 2024-11-09 06:31:05 +01:00
remove prev event fetch limit
This commit is contained in:
parent
38effda799
commit
0cb22996be
1 changed files with 6 additions and 4 deletions
|
@ -1016,10 +1016,11 @@ pub fn handle_incoming_pdu<'a>(
|
||||||
// 8. if not timeline event: stop
|
// 8. if not timeline event: stop
|
||||||
if !is_timeline_event
|
if !is_timeline_event
|
||||||
|| incoming_pdu.origin_server_ts
|
|| incoming_pdu.origin_server_ts
|
||||||
< (utils::millis_since_unix_epoch() - 1000 * 60 * 20)
|
< db.rooms
|
||||||
.try_into()
|
.first_pdu_in_room(&room_id)
|
||||||
.expect("time is valid")
|
.map_err(|_| "Error loading first room event.".to_owned())?
|
||||||
// Not older than 20 mins
|
.expect("Room exists")
|
||||||
|
.origin_server_ts
|
||||||
{
|
{
|
||||||
let elapsed = start_time.elapsed();
|
let elapsed = start_time.elapsed();
|
||||||
warn!(
|
warn!(
|
||||||
|
@ -1031,6 +1032,7 @@ pub fn handle_incoming_pdu<'a>(
|
||||||
return Ok(None);
|
return Ok(None);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO: make not recursive
|
||||||
// 9. Fetch any missing prev events doing all checks listed here starting at 1. These are timeline events
|
// 9. Fetch any missing prev events doing all checks listed here starting at 1. These are timeline events
|
||||||
fetch_and_handle_events(
|
fetch_and_handle_events(
|
||||||
db,
|
db,
|
||||||
|
|
Loading…
Reference in a new issue