diff --git a/client/cli/src/config.rs b/client/cli/src/config.rs index a143f14a9b89f..a011aff513116 100644 --- a/client/cli/src/config.rs +++ b/client/cli/src/config.rs @@ -466,9 +466,9 @@ pub trait CliConfiguration: Sized { /// /// By default this is retrieved from [`WebRTCCertificateParams`] if it is available. Otherwise /// its [`WebRTCConfig::Ephemeral`]. - fn webrtc(&self, net_config_dir: &PathBuf) -> Result { + fn webrtc(&self, config_dir: &PathBuf) -> Result { self.webrtc_certificate_params() - .map(|x| x.webrtc_certificate(net_config_dir)) + .map(|x| x.webrtc_certificate(config_dir)) .unwrap_or_else(|| Ok(WebRTCConfig::Ephemeral)) } @@ -520,7 +520,7 @@ pub trait CliConfiguration: Sized { }, ); let node_key = self.node_key(&net_config_dir)?; - let webrtc = self.webrtc(&net_config_dir)?; + let webrtc = self.webrtc(&config_dir)?; let role = self.role(is_dev)?; let max_runtime_instances = self.max_runtime_instances()?.unwrap_or(8); let is_validator = role.is_authority(); diff --git a/client/cli/src/params/webrtc_certificate_params.rs b/client/cli/src/params/webrtc_certificate_params.rs index 8e89991408c7b..8c12f0e615a43 100644 --- a/client/cli/src/params/webrtc_certificate_params.rs +++ b/client/cli/src/params/webrtc_certificate_params.rs @@ -35,7 +35,7 @@ pub struct WebRTCCertificateParams { /// The contents of the file are parsed as follows: /// /// The file must contain an ASCII PEM encoded - /// [`webrtc::peer_connection::certificate::RTCCertificate`]. + /// [`webrtc::peer_connection::certificate::RTCCertificate`]. /// /// If the file does not exist, it is created with a newly generated certificate. #[clap(long, value_name = "FILE")] @@ -53,8 +53,8 @@ pub struct WebRTCCertificateParams { impl WebRTCCertificateParams { /// Create a `WebRTCConfig` from the given `WebRTCCertificateParams` in the context - /// of an optional network config storage directory. - pub fn webrtc_certificate(&self, net_config_dir: &PathBuf) -> error::Result { + /// of an optional base config storage directory. + pub fn webrtc_certificate(&self, config_dir: &PathBuf) -> error::Result { if let Some(true) = self.webrtc_certificate_ephemeral { return Ok(WebRTCConfig::Ephemeral) } @@ -62,7 +62,7 @@ impl WebRTCCertificateParams { let filename = self .webrtc_certificate_file .clone() - .unwrap_or_else(|| net_config_dir.join(WEBRTC_CERTIFICATE_FILENAME)); + .unwrap_or_else(|| config_dir.join(WEBRTC_CERTIFICATE_FILENAME)); Ok(WebRTCConfig::File(filename)) }