Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Initialize private tx logger only if private tx functionality is enabled #10758

Merged
merged 3 commits into from
Jun 19, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions parity/configuration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -917,7 +917,10 @@ impl Configuration {
let provider_conf = ProviderConfig {
validator_accounts: to_addresses(&self.args.arg_private_validators)?,
signer_account: self.args.arg_private_signer.clone().and_then(|account| to_address(Some(account)).ok()),
logs_path: Some(dirs.base),
logs_path: match self.args.flag_private_enabled {
true => Some(dirs.base),
false => None,
}
};

let encryptor_conf = EncryptorConfig {
Expand Down Expand Up @@ -1455,11 +1458,7 @@ mod tests {
net_settings: Default::default(),
ipfs_conf: Default::default(),
secretstore_conf: Default::default(),
private_provider_conf: ProviderConfig {
validator_accounts: Default::default(),
signer_account: Default::default(),
logs_path: Some(Directories::default().base),
},
private_provider_conf: Default::default(),
private_encryptor_conf: Default::default(),
private_tx_enabled: false,
name: "".into(),
Expand Down