From c1eae150262f8e71e6b3545eac7f3fa072bc3ddd Mon Sep 17 00:00:00 2001 From: Chris Cochrun Date: Thu, 30 Apr 2026 13:41:08 -0500 Subject: [PATCH] [work]: idk --- src/main.rs | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/main.rs b/src/main.rs index 0a34ae3..dc21ce5 100755 --- a/src/main.rs +++ b/src/main.rs @@ -2222,9 +2222,16 @@ where fn add_library() -> Task { cosmic::Task::future(library::add_db()).then(|res| { - Task::perform(Library::new(Arc::new(res.expect("probs"))), |x| { - cosmic::Action::App(Message::AddLibrary(x)) - }) + Task::perform( + Library::new(Arc::new(match res { + Ok(db) => db, + Err(e) => { + error!("{e}"); + panic!("{e}") + } + })), + |x| cosmic::Action::App(Message::AddLibrary(x)), + ) }) }