diff options
Diffstat (limited to 'server/src/main.rs')
| -rw-r--r-- | server/src/main.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/server/src/main.rs b/server/src/main.rs index 2bb0d61..fe55ef6 100644 --- a/server/src/main.rs +++ b/server/src/main.rs @@ -32,6 +32,7 @@ pub mod request_info; pub mod responders; pub mod routes; pub mod ui; +pub mod ui_responder; #[rocket::main] async fn main() { @@ -57,7 +58,7 @@ async fn main() { pub struct State { pub config: Config, - pub cache: Cache, + pub cache: Arc<Cache>, pub database: Arc<dyn Database>, pub session_key: SessionKey, } @@ -86,7 +87,7 @@ pub fn create_state() -> Result<Arc<State>> { // let db_storage = jellykv::memory::new(); let state = Arc::new(State { - cache: Cache::new(Box::new(cache_storage), config.max_memory_cache_size), + cache: Cache::new(Box::new(cache_storage), config.max_memory_cache_size).into(), database: Arc::new(db_storage), session_key: SessionKey::parse(&config.session_key)?, config, |