Skip to content

Commit 188c908

Browse files
committed
Formatting
1 parent 16022c7 commit 188c908

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

src/utils.rs

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -299,8 +299,6 @@ pub fn to_key_code(key_str: &str) -> Option<Code> {
299299
}
300300

301301
pub fn get_config_installation_dir() -> String {
302-
303-
304302
if cfg!(target_os = "windows") {
305303
std::env::var("LOCALAPPDATA").unwrap()
306304
} else {
@@ -310,7 +308,6 @@ pub fn get_config_installation_dir() -> String {
310308

311309
pub fn get_config_file_path() -> String {
312310
let home = get_config_installation_dir();
313-
314311

315312
if cfg!(target_os = "windows") {
316313
home + "\\rustcast\\config.toml"
@@ -335,9 +332,10 @@ pub fn create_config_file_if_not_exists(
335332
) -> Result<(), std::io::Error> {
336333
// check if file exists
337334
if let Ok(exists) = std::fs::metadata(file_path)
338-
&& exists.is_file() {
339-
return Ok(());
340-
}
335+
&& exists.is_file()
336+
{
337+
return Ok(());
338+
}
341339

342340
let path = Path::new(&file_path);
343341
if let Some(parent) = path.parent() {

0 commit comments

Comments
 (0)