mirror of https://github.com/Tim-Paik/neutauri.git
fix: initialization_script now read the corresponding file instead of directly executing
This commit is contained in:
parent
92206f6ddd
commit
a5fe6d8ea9
|
@ -284,7 +284,13 @@ impl Config {
|
|||
Some(path) => fs::read_to_string(path.as_path()).ok(),
|
||||
None => None,
|
||||
},
|
||||
initialization_script: self.initialization_script.clone(),
|
||||
initialization_script: {
|
||||
if let Some(script_path) = &self.initialization_script {
|
||||
fs::read_to_string(Path::new(script_path)).ok()
|
||||
} else {
|
||||
None
|
||||
}
|
||||
},
|
||||
})
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue