🔨 Refactors db connection

This commit is contained in:
Daniel Svitan
2025-05-11 08:48:43 +02:00
parent 05982880d3
commit d5bb5089da
2 changed files with 58 additions and 14 deletions
+1 -1
View File
@@ -14,7 +14,7 @@ async fn index() -> &'static str {
fn rocket() -> _ {
dotenv::dotenv().ok();
let db_path = dotenv::var("DB_PATH").expect("DB_PATH is not set");
let db = db::new_conn(&db_path);
let db = db::Conn::new(&db_path);
rocket::build().mount("/", routes![index])
}