aboutsummaryrefslogtreecommitdiff
path: root/src/utils/time.rs
diff options
context:
space:
mode:
authorAdaShoelace <adashoelace@gmail.com>2021-01-21 22:24:15 +0100
committerAdaShoelace <adashoelace@gmail.com>2021-01-21 22:24:15 +0100
commit861a986567310dfe9ccd85d2976b0ebfb683c818 (patch)
tree65ec9c5397bf7de009f3484ea161e77df2120f67 /src/utils/time.rs
parente6f9ce2ed5da0eb833d548a613c3b70360c9f4b5 (diff)
Change to serde
Change config serializer to serde in order to get cleaner config types.
Diffstat (limited to 'src/utils/time.rs')
-rw-r--r--src/utils/time.rs10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/utils/time.rs b/src/utils/time.rs
index 3149ce6..fcfb691 100644
--- a/src/utils/time.rs
+++ b/src/utils/time.rs
@@ -1,13 +1,13 @@
-use crate::types::Config;
+use crate::config::CONFIG;
use chrono::prelude::*;
-pub fn get_time(config: &Config) -> String {
+pub fn get_time() -> String {
let now = Local::now();
format!(
" {} {} {}",
- config.time.icon,
- now.format(&config.time.format),
- config.seperator
+ CONFIG.time.icon,
+ now.format(&CONFIG.time.format),
+ CONFIG.seperator
)
}