add formal wrapping for api state
Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
parent
5c258f41c8
commit
ccef1a4c8b
4 changed files with 27 additions and 7 deletions
|
@ -3,8 +3,7 @@ mod auth;
|
|||
mod handler;
|
||||
mod request;
|
||||
mod response;
|
||||
|
||||
use std::sync::Arc;
|
||||
mod state;
|
||||
|
||||
use axum::{
|
||||
response::IntoResponse,
|
||||
|
@ -15,11 +14,10 @@ use conduit::{err, Server};
|
|||
use http::Uri;
|
||||
|
||||
use self::handler::RouterExt;
|
||||
pub use self::state::State;
|
||||
pub(super) use self::{args::Args as Ruma, response::RumaResponse};
|
||||
use crate::{client, server};
|
||||
|
||||
pub type State = Arc<service::Services>;
|
||||
|
||||
pub fn build(router: Router<State>, server: &Server) -> Router<State> {
|
||||
let config = &server.config;
|
||||
let router = router
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue