mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-30 09:37:55 +00:00
Make network_config_path an Option (#5661)
* Make network_config_path an Option * Fix network tests * Use None as the network config path * Fix cli * Don't make PathBuf an Option in a cli context
This commit is contained in:
@@ -184,7 +184,9 @@ impl<B: BlockT + 'static, H: ExHashT> NetworkWorker<B, H> {
|
||||
pub fn new(params: Params<B, H>) -> Result<NetworkWorker<B, H>, Error> {
|
||||
let (to_worker, from_worker) = tracing_unbounded("mpsc_network_worker");
|
||||
|
||||
fs::create_dir_all(¶ms.network_config.net_config_path)?;
|
||||
if let Some(path) = params.network_config.net_config_path {
|
||||
fs::create_dir_all(&path)?;
|
||||
}
|
||||
|
||||
// List of multiaddresses that we know in the network.
|
||||
let mut known_addresses = Vec::new();
|
||||
|
||||
Reference in New Issue
Block a user