Skip to content

Commit

Permalink
rusk-wallet: use stake_owner key for withdraw
Browse files Browse the repository at this point in the history
  • Loading branch information
Neotamandua committed Dec 27, 2024
1 parent 12d40ed commit f4882e6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion rusk-wallet/src/wallet/transaction.rs
Original file line number Diff line number Diff line change
Expand Up @@ -536,7 +536,10 @@ impl<F: SecureWalletFile + Debug> Wallet<F> {
let reward = Dusk::from(reward);

let mut sender_sk = self.derive_bls_sk(sender_idx);
let mut stake_owner_sk = self.derive_bls_sk(sender_idx);

let stake_pk = self.public_key(sender_idx)?;
let stake_owner_idx = self.find_stake_owner_idx(stake_pk).await?;
let mut stake_owner_sk = self.derive_bls_sk(stake_owner_idx);

let withdraw = moonlight_stake_reward(
&mut rng,
Expand Down

0 comments on commit f4882e6

Please sign in to comment.