From 92f3ec6856b2e39ea4a7dca8a4e1d7e8ac01acda Mon Sep 17 00:00:00 2001 From: matias-gonz Date: Fri, 27 Sep 2024 13:19:08 -0300 Subject: [PATCH] Remove get_consensus_port --- zk_toolbox/crates/config/src/general.rs | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/zk_toolbox/crates/config/src/general.rs b/zk_toolbox/crates/config/src/general.rs index 1e2c9006aea..b8a7b35ba34 100644 --- a/zk_toolbox/crates/config/src/general.rs +++ b/zk_toolbox/crates/config/src/general.rs @@ -11,7 +11,7 @@ use zksync_protobuf_config::{decode_yaml_repr, encode_yaml_repr}; use crate::{ consts::GENERAL_FILE, traits::{ConfigWithL2RpcUrl, FileConfigWithDefaultName, ReadConfig, SaveConfig}, - ChainConfig, DEFAULT_CONSENSUS_PORT, + ChainConfig, }; pub struct RocksDbs { @@ -113,14 +113,6 @@ pub fn set_file_artifacts(config: &mut GeneralConfig, file_artifacts: FileArtifa set_artifact_path!(config.core_object_store, file_artifacts.core_object_store); } -pub fn get_consensus_port(config: &GeneralConfig) -> u16 { - config - .consensus_config - .as_ref() - .map(|c| c.server_addr.port()) - .unwrap_or(DEFAULT_CONSENSUS_PORT) -} - pub fn override_config(shell: &Shell, path: PathBuf, chain: &ChainConfig) -> anyhow::Result<()> { let chain_config_path = chain.path_to_general_config(); let override_config = serde_yaml::from_str(&shell.read_file(path)?)?;