de-global services for services
Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
parent
992c0a1e58
commit
010e4ee35a
85 changed files with 2480 additions and 1887 deletions
|
@ -3,7 +3,6 @@ use std::sync::Arc;
|
|||
use axum::extract::State;
|
||||
use conduit::{Error, Result};
|
||||
use ruma::api::{client::error::ErrorKind, federation::event::get_room_state};
|
||||
use service::sending::convert_to_outgoing_federation_event;
|
||||
|
||||
use crate::Ruma;
|
||||
|
||||
|
@ -44,7 +43,11 @@ pub(crate) async fn get_room_state_route(
|
|||
.state_full_ids(shortstatehash)
|
||||
.await?
|
||||
.into_values()
|
||||
.map(|id| convert_to_outgoing_federation_event(services.rooms.timeline.get_pdu_json(&id).unwrap().unwrap()))
|
||||
.map(|id| {
|
||||
services
|
||||
.sending
|
||||
.convert_to_outgoing_federation_event(services.rooms.timeline.get_pdu_json(&id).unwrap().unwrap())
|
||||
})
|
||||
.collect();
|
||||
|
||||
let auth_chain_ids = services
|
||||
|
@ -61,7 +64,7 @@ pub(crate) async fn get_room_state_route(
|
|||
.timeline
|
||||
.get_pdu_json(&id)
|
||||
.ok()?
|
||||
.map(convert_to_outgoing_federation_event)
|
||||
.map(|pdu| services.sending.convert_to_outgoing_federation_event(pdu))
|
||||
})
|
||||
.collect(),
|
||||
pdus,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue