From c630a3d95fcba117eeeeb03a0c656ef26bea3072 Mon Sep 17 00:00:00 2001 From: mia Date: Fri, 3 May 2024 18:25:03 -0700 Subject: refactor scope access endpoints --- src/server/mod.rs | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) (limited to 'src/server/mod.rs') diff --git a/src/server/mod.rs b/src/server/mod.rs index a583f85..b6dd451 100644 --- a/src/server/mod.rs +++ b/src/server/mod.rs @@ -1,8 +1,7 @@ +mod account; mod admin; mod config; -mod falx; mod login; -mod panel; mod store; use std::{future::IntoFuture, path::PathBuf, sync::Arc}; @@ -42,12 +41,10 @@ pub async fn serve() -> eyre::Result<()> { let app = Router::new() .pipe(login::bind) - .pipe(falx::bind) - .pipe(panel::bind) + .pipe(account::bind) .with_state(ApiState { store, cookie_domain: CookieDomain(config.cookie_domain), - web_base: WebBase(config.web_base), handoffs: Handoffs(Arc::new(config.handoffs)), }) .fallback(get(|| async { @@ -73,16 +70,12 @@ pub async fn serve() -> eyre::Result<()> { struct ApiState { pub store: Store, pub cookie_domain: CookieDomain, - pub web_base: WebBase, pub handoffs: Handoffs, } #[derive(Clone)] struct CookieDomain(Option); -#[derive(Clone)] -struct WebBase(String); - #[derive(Clone)] struct Handoffs(Arc>); -- cgit 1.4.1