Skip to content

Commit 1492574

Browse files
obycodefdefelici
andauthored
refactor: improve address getter
Co-authored-by: Federico De Felici <fdf8210@gmail.com>
1 parent 666f424 commit 1492574

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

stackslib/src/main.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -423,11 +423,7 @@ fn main() {
423423
.unwrap();
424424

425425
println!("Verified: {:#?}", tx.verify());
426-
let address = if tx.is_mainnet() {
427-
tx.auth.origin().address_mainnet()
428-
} else {
429-
tx.auth.origin().address_testnet()
430-
};
426+
let address = tx.auth.origin().get_address(tx.is_mainnet())
431427
println!("Address: {}", address);
432428

433429
println!("{:#?}", &tx);

0 commit comments

Comments
 (0)