simplify get_pdu() interface; eliminate unconditional Arc
Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
parent
58be22e695
commit
6175e72f1c
16 changed files with 51 additions and 52 deletions
|
@ -1,7 +1,7 @@
|
|||
use std::sync::Arc;
|
||||
|
||||
use axum::extract::State;
|
||||
use conduit::{err, pdu::PduBuilder, utils::BoolExt, Err, Error, Result};
|
||||
use conduit::{err, pdu::PduBuilder, utils::BoolExt, Err, Error, PduEvent, Result};
|
||||
use ruma::{
|
||||
api::client::{
|
||||
error::ErrorKind,
|
||||
|
@ -97,7 +97,7 @@ pub(crate) async fn get_state_events_route(
|
|||
.room_state_full(&body.room_id)
|
||||
.await?
|
||||
.values()
|
||||
.map(|pdu| pdu.to_state_event())
|
||||
.map(PduEvent::to_state_event)
|
||||
.collect(),
|
||||
})
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue