Skip to content

Commit

Permalink
cli: rename Tx arg tx_code_path to tx_reveal_code_path
Browse files Browse the repository at this point in the history
  • Loading branch information
tzemanovic committed May 21, 2023
1 parent a9a3e32 commit de50551
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions apps/src/lib/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3165,7 +3165,7 @@ pub mod args {
gas_limit: self.gas_limit,
signing_key: self.signing_key.map(|x| ctx.get_cached(&x)),
signer: self.signer.map(|x| ctx.get(&x)),
tx_code_path: ctx.read_wasm(self.tx_code_path),
tx_reveal_code_path: ctx.read_wasm(self.tx_reveal_code_path),
password: self.password,
expiration: self.expiration,
chain_id: self.chain_id,
Expand Down Expand Up @@ -3251,7 +3251,7 @@ pub mod args {
let expiration = EXPIRATION_OPT.parse(matches);
let signing_key = SIGNING_KEY_OPT.parse(matches);
let signer = SIGNER.parse(matches);
let tx_code_path = PathBuf::from(TX_REVEAL_PK);
let tx_reveal_code_path = PathBuf::from(TX_REVEAL_PK);
let chain_id = CHAIN_ID_OPT.parse(matches);
let password = None;
Self {
Expand All @@ -3268,7 +3268,7 @@ pub mod args {
expiration,
signing_key,
signer,
tx_code_path,
tx_reveal_code_path,
password,
chain_id,
}
Expand Down
4 changes: 2 additions & 2 deletions shared/src/ledger/args.rs
Original file line number Diff line number Diff line change
Expand Up @@ -400,8 +400,8 @@ pub struct Tx<C: NamadaTypes = SdkTypes> {
pub signing_key: Option<C::Keypair>,
/// Sign the tx with the keypair of the public key of the given address
pub signer: Option<C::Address>,
/// Path to the TX WASM code file
pub tx_code_path: C::Data,
/// Path to the TX WASM code file to reveal PK
pub tx_reveal_code_path: C::Data,
/// Password to decrypt key
pub password: Option<String>,
}
Expand Down
2 changes: 1 addition & 1 deletion shared/src/ledger/tx.rs
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ pub async fn submit_reveal_pk_aux<
let addr: Address = public_key.into();
println!("Submitting a tx to reveal the public key for address {addr}...");
let tx_data = public_key.try_to_vec().map_err(Error::EncodeKeyFailure)?;
let tx_code = args.tx_code_path.clone();
let tx_code = args.tx_reveal_code_path.clone();
let tx = Tx::new(
tx_code,
Some(tx_data),
Expand Down

0 comments on commit de50551

Please sign in to comment.