mirror of
https://github.com/uqbar-dao/nectar.git
synced 2024-11-23 03:44:04 +03:00
fix: wrap fakechain-port flag usage in feature always
This commit is contained in:
parent
430d58695a
commit
22e676b9a3
@ -99,15 +99,22 @@ async fn main() {
|
||||
.await
|
||||
.expect("failed to save new eth provider config!");
|
||||
}
|
||||
let local_chain_port = matches
|
||||
.get_one::<u16>("fakechain-port")
|
||||
.cloned()
|
||||
.unwrap_or(8545);
|
||||
eth_provider_config.push(lib::eth::ProviderConfig {
|
||||
chain_id: 31337,
|
||||
trusted: true,
|
||||
provider: lib::eth::NodeOrRpcUrl::RpcUrl(format!("ws://localhost:{}", local_chain_port)),
|
||||
});
|
||||
|
||||
#[cfg(feature = "simulation-mode")]
|
||||
{
|
||||
let local_chain_port = matches
|
||||
.get_one::<u16>("fakechain-port")
|
||||
.cloned()
|
||||
.unwrap_or(8545);
|
||||
eth_provider_config.push(lib::eth::ProviderConfig {
|
||||
chain_id: 31337,
|
||||
trusted: true,
|
||||
provider: lib::eth::NodeOrRpcUrl::RpcUrl(format!(
|
||||
"ws://localhost:{}",
|
||||
local_chain_port
|
||||
)),
|
||||
});
|
||||
}
|
||||
|
||||
// kernel receives system messages via this channel, all other modules send messages
|
||||
let (kernel_message_sender, kernel_message_receiver): (MessageSender, MessageReceiver) =
|
||||
|
Loading…
Reference in New Issue
Block a user