diff --git a/src/config_management.rs b/src/config_management.rs index 4ef87a9..4370abb 100644 --- a/src/config_management.rs +++ b/src/config_management.rs @@ -18,12 +18,14 @@ pub fn initialize() -> PathBuf { std::fs::create_dir_all(&config_directories).unwrap_or_default(); std::fs::File::create(&config_path).unwrap(); default(); + } else { + merge_previous_version(); } config_path } -pub fn merge_previous_version() -> Option { +fn merge_previous_version() -> Option { let config_path: PathBuf = Path::new(&get_user_data_dir().unwrap()) .join("blue-recorder") .join("config.ini"); diff --git a/src/main.rs b/src/main.rs index b48fc11..278355a 100644 --- a/src/main.rs +++ b/src/main.rs @@ -21,7 +21,6 @@ fn main() { } let builder: Builder = Builder::from_file(Path::new("windows/ui.glade")); - config_management::merge_previous_version(); config_management::initialize(); // get Objects from UI