Skip to content

Commit

Permalink
build: appease clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
chadoh committed Aug 11, 2023
1 parent 29e781f commit 23fd270
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmd/crates/soroban-spec-typescript/src/boilerplate.rs
Original file line number Diff line number Diff line change
Expand Up @@ -95,15 +95,15 @@ impl Project {
contract_id: &str,
network_passphrase: &str,
) -> std::io::Result<()> {
let networks = self.format_networks_object(contract_id, network_passphrase);
let networks = Project::format_networks_object(contract_id, network_passphrase);
let types_and_fns = generate(spec);
fs::OpenOptions::new()
.append(true)
.open(self.0.join("src/index.ts"))?
.write_all(format!("\n\n{networks}\n\n{types_and_fns}").as_bytes())
}

fn format_networks_object(&self, contract_id: &str, network_passphrase: &str) -> String {
fn format_networks_object(contract_id: &str, network_passphrase: &str) -> String {
let network = if network_passphrase == NETWORK_PASSPHRASE_FUTURENET {
"futurenet"
} else if network_passphrase == NETWORK_PASSPHRASE_LOCALNET {
Expand Down

0 comments on commit 23fd270

Please sign in to comment.