Reformats Code

This commit is contained in:
2024-02-25 02:11:17 -03:00
parent 11f01a6156
commit b8b8d5713f
13 changed files with 52 additions and 48 deletions

View File

@@ -1,5 +1,5 @@
use std::env;
use cached::proc_macro::cached;
use std::env;
#[derive(Clone)]
pub struct ConfigServer {
@@ -9,14 +9,12 @@ pub struct ConfigServer {
#[cached]
pub fn get_config_server() -> ConfigServer {
let h = option_env!("HOST")
.unwrap_or("localhost").to_string();
let h = option_env!("HOST").unwrap_or("localhost").to_string();
let p = option_env!("PORT").unwrap_or("8500")
.parse::<u16>().unwrap();
let p = option_env!("PORT")
.unwrap_or("8500")
.parse::<u16>()
.unwrap();
ConfigServer {
host: h,
port: p,
}
}
ConfigServer { host: h, port: p }
}