mirror of
https://github.com/mCaptcha/mCaptcha.git
synced 2026-02-11 10:05:41 +00:00
Remove redunant format
This commit is contained in:
@@ -154,21 +154,15 @@ impl Settings {
|
|||||||
if let Ok(path) = env::var("MCAPTCHA_CONFIG") {
|
if let Ok(path) = env::var("MCAPTCHA_CONFIG") {
|
||||||
let absolute_path = Path::new(&path).canonicalize().unwrap();
|
let absolute_path = Path::new(&path).canonicalize().unwrap();
|
||||||
log::info!(
|
log::info!(
|
||||||
"{}",
|
"Loading config file from {}",
|
||||||
format!(
|
absolute_path.to_str().unwrap()
|
||||||
"Loading config file from {}",
|
|
||||||
absolute_path.to_str().unwrap()
|
|
||||||
)
|
|
||||||
);
|
);
|
||||||
s.merge(File::with_name(absolute_path.to_str().unwrap()))?;
|
s.merge(File::with_name(absolute_path.to_str().unwrap()))?;
|
||||||
} else if Path::new(CURRENT_DIR).exists() {
|
} else if Path::new(CURRENT_DIR).exists() {
|
||||||
let absolute_path = fs::canonicalize(CURRENT_DIR).unwrap();
|
let absolute_path = fs::canonicalize(CURRENT_DIR).unwrap();
|
||||||
log::info!(
|
log::info!(
|
||||||
"{}",
|
"Loading config file from {}",
|
||||||
format!(
|
absolute_path.to_str().unwrap()
|
||||||
"Loading config file from {}",
|
|
||||||
absolute_path.to_str().unwrap()
|
|
||||||
)
|
|
||||||
);
|
);
|
||||||
// merging default config from file
|
// merging default config from file
|
||||||
s.merge(File::with_name(absolute_path.to_str().unwrap()))?;
|
s.merge(File::with_name(absolute_path.to_str().unwrap()))?;
|
||||||
|
|||||||
Reference in New Issue
Block a user