From fd0fdb5f688dd684ee584912b296d2b1969bc124 Mon Sep 17 00:00:00 2001 From: 0xf8 <0xf8.dev@proton.me> Date: Wed, 21 Jun 2023 16:48:27 -0400 Subject: [PATCH] Wrap database for dbtool --- src/main_dbtool.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main_dbtool.rs b/src/main_dbtool.rs index e7ae211..bcaee96 100644 --- a/src/main_dbtool.rs +++ b/src/main_dbtool.rs @@ -43,7 +43,9 @@ async fn main() -> Result<()> { // Load database let db = Database::init(config).await?; - match dbtool::start(&db).await { + let wrapper = DatabaseWrapper { db }; + + match dbtool::start(&wrapper.db).await { Ok(_) => (), Err(e) => error!("{e}") }