aboutsummaryrefslogtreecommitdiffstats
path: root/askama_shared/src/path.rs
diff options
context:
space:
mode:
Diffstat (limited to 'askama_shared/src/path.rs')
-rw-r--r--askama_shared/src/path.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/askama_shared/src/path.rs b/askama_shared/src/path.rs
index f6eef40..bc329e5 100644
--- a/askama_shared/src/path.rs
+++ b/askama_shared/src/path.rs
@@ -27,7 +27,7 @@ pub fn find_template_from_path(path: &str, start_at: Option<&Path>) -> PathBuf {
}
}
- let config = Config::from_file();
+ let config = Config::new();
for dir in &config.dirs {
let rooted = dir.join(path);
if rooted.exists() {
@@ -39,7 +39,7 @@ pub fn find_template_from_path(path: &str, start_at: Option<&Path>) -> PathBuf {
}
pub fn template_dirs() -> Vec<PathBuf> {
- Config::from_file().dirs
+ Config::new().dirs
}
struct Config {
@@ -47,7 +47,7 @@ struct Config {
}
impl Config {
- fn from_file() -> Config {
+ fn new() -> Config {
let root = PathBuf::from(env::var("CARGO_MANIFEST_DIR").unwrap());
let filename = root.join(CONFIG_FILE_NAME);