finish implementing better state store
This commit is contained in:
parent
31f60ad6fd
commit
3eabaa2a95
10 changed files with 645 additions and 526 deletions
|
@ -128,7 +128,7 @@ pub async fn get_message_events_route(
|
|||
get_message_events::Direction::Forward => {
|
||||
let events_after = db
|
||||
.rooms
|
||||
.pdus_after(&sender_user, &body.room_id, from)
|
||||
.pdus_after(&sender_user, &body.room_id, from)?
|
||||
.take(limit)
|
||||
.filter_map(|r| r.ok()) // Filter out buggy events
|
||||
.filter_map(|(pdu_id, pdu)| {
|
||||
|
@ -158,7 +158,7 @@ pub async fn get_message_events_route(
|
|||
get_message_events::Direction::Backward => {
|
||||
let events_before = db
|
||||
.rooms
|
||||
.pdus_until(&sender_user, &body.room_id, from)
|
||||
.pdus_until(&sender_user, &body.room_id, from)?
|
||||
.take(limit)
|
||||
.filter_map(|r| r.ok()) // Filter out buggy events
|
||||
.filter_map(|(pdu_id, pdu)| {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue