From 4e6466af1329f7b9e341df2e76ab696d11f80c93 Mon Sep 17 00:00:00 2001 From: FxQnLr Date: Thu, 27 Apr 2023 10:08:20 +0200 Subject: version bump, cargo fmt and cargo update --- src/config.rs | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'src/config.rs') diff --git a/src/config.rs b/src/config.rs index 817d22b..61db1c7 100644 --- a/src/config.rs +++ b/src/config.rs @@ -1,11 +1,12 @@ use std::{ - fs::{File, create_dir_all}, - io::{Read, Write}, path::Path, + fs::{create_dir_all, File}, + io::{Read, Write}, + path::Path, }; use serde::{Deserialize, Serialize}; -use crate::{error::MLE, db::db_setup}; +use crate::{db::db_setup, error::MLE}; #[derive(Debug, Clone, Serialize, Deserialize)] pub struct Cfg { @@ -23,7 +24,11 @@ impl Cfg { pub fn init(path: Option) -> MLE { let configfile = match path.clone() { Some(p) => String::from(p), - None => dirs::config_dir().unwrap().join("modlist.toml").to_string_lossy().to_string(), + None => dirs::config_dir() + .unwrap() + .join("modlist.toml") + .to_string_lossy() + .to_string(), }; let mut file = match File::open(&configfile) { -- cgit v1.2.3