Adds basic structure

This commit is contained in:
2026-07-05 10:24:47 +02:00
parent ee79500c87
commit aef4abc72c
4 changed files with 139 additions and 2 deletions
+16
View File
@@ -0,0 +1,16 @@
use diesel::PgConnection;
use std::sync::{Arc, Mutex};
mod action;
pub struct AppState {
pub db: Arc<Mutex<PgConnection>>,
}
impl AppState {
pub fn new(db: PgConnection) -> Self {
Self {
db: Arc::new(Mutex::new(db)),
}
}
}