mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-03-31 16:45:27 +00:00
change sqlite wrapper to rusqlite, update database api
This commit is contained in:
parent
7b9937eac1
commit
490338930d
4 changed files with 19 additions and 20 deletions
|
|
@ -2,6 +2,7 @@ mod app;
|
|||
|
||||
use app::App;
|
||||
use gtk::glib::{user_config_dir, ExitCode};
|
||||
use sqlite::Connection;
|
||||
use std::{fs::create_dir_all, sync::Arc};
|
||||
|
||||
fn main() -> ExitCode {
|
||||
|
|
@ -20,8 +21,8 @@ fn main() -> ExitCode {
|
|||
profile_database_path.push("database.sqlite3");
|
||||
|
||||
// Init database connection
|
||||
let profile_database_connection = match sqlite::open(profile_database_path) {
|
||||
Ok(profile_database_connection) => Arc::new(profile_database_connection),
|
||||
let profile_database_connection = match Connection::open(profile_database_path) {
|
||||
Ok(connection) => Arc::new(connection),
|
||||
Err(error) => panic!("Failed to connect profile database: {error}"),
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue