From 5b74fa4a69a7c407d3cd775688745aa79120f42b Mon Sep 17 00:00:00 2001 From: rasul Date: Sat, 1 Feb 2020 15:08:42 -0600 Subject: [PATCH] use .into() because it's easier --- src/config.rs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/config.rs b/src/config.rs index 1421ff5..ecf4572 100644 --- a/src/config.rs +++ b/src/config.rs @@ -28,6 +28,8 @@ pub struct Config { pub template_directory: PathBuf, #[serde(default)] pub static_directory: PathBuf, + #[serde(default)] + pub salt: String, } impl Default for Config { @@ -37,9 +39,10 @@ impl Default for Config { url: "http://127.0.0.1:9214".into(), log_level: LogLevel::info, log_file: None, - data_directory: PathBuf::from("data"), - template_directory: PathBuf::from("templates"), - static_directory: PathBuf::from("static"), + data_directory: "data".into(), + template_directory: "templates".into(), + static_directory: "static".into(), + salt: "salt and pepper".into(), } } }