Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
rzadp committed Mar 14, 2024
1 parent 5c8a719 commit 08f1d3d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion templates/minimal/node/src/chain_spec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ pub fn development_config() -> Result<ChainSpec, String> {

/// Configure initial storage state for FRAME pallets.
fn testnet_genesis() -> Value {
use sp_runtime::traits::Get;
use runtime::interface::{Balance, MinimumBalance};
use sp_runtime::traits::Get;
let endowment = <MinimumBalance as Get<Balance>>::get().max(1) * 1000;
let balances = AccountKeyring::iter()
.map(|a| (a.to_account_id(), endowment))
Expand Down
2 changes: 1 addition & 1 deletion templates/minimal/node/src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ impl std::str::FromStr for Consensus {
} else if let Some(block_time) = s.strip_prefix("manual-seal-") {
Consensus::ManualSeal(block_time.parse().map_err(|_| "invalid block time")?)
} else {
return Err("incorrect consensus identifier".into())
return Err("incorrect consensus identifier".into());
})
}
}
Expand Down
5 changes: 3 additions & 2 deletions templates/minimal/node/src/command.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,9 @@ impl SubstrateCli for Cli {
fn load_spec(&self, id: &str) -> Result<Box<dyn sc_service::ChainSpec>, String> {
Ok(match id {
"dev" => Box::new(chain_spec::development_config()?),
path =>
Box::new(chain_spec::ChainSpec::from_json_file(std::path::PathBuf::from(path))?),
path => {
Box::new(chain_spec::ChainSpec::from_json_file(std::path::PathBuf::from(path))?)
},
})
}
}
Expand Down

0 comments on commit 08f1d3d

Please sign in to comment.