diff --git a/config/Cargo.toml b/config/Cargo.toml index 887ded11..ed03b0f8 100644 --- a/config/Cargo.toml +++ b/config/Cargo.toml @@ -9,7 +9,7 @@ publish = false serde = "1" serde_derive = "1" toml = "0.4" -dirs = "1" +dirs = "1.0.3" grin_servers = { path = "../servers" } grin_p2p = { path = "../p2p" } diff --git a/config/src/config.rs b/config/src/config.rs index 36bf7933..cbe08409 100644 --- a/config/src/config.rs +++ b/config/src/config.rs @@ -14,6 +14,7 @@ //! Configuration file management +use dirs; use std::env; use std::fs::{self, File}; use std::io::prelude::*; @@ -43,7 +44,7 @@ const GRIN_WALLET_DIR: &'static str = "wallet_data"; fn get_grin_path() -> Result { // Check if grin dir exists let grin_path = { - match env::home_dir() { + match dirs::home_dir() { Some(mut p) => { p.push(GRIN_HOME); p