pub fn decrease_validator_stake_with_vote(
    program_id: &Pubkey,
    stake_pool: &StakePool,
    stake_pool_address: &Pubkey,
    vote_account_address: &Pubkey,
    lamports: u64,
) -> Instruction {
    let pool_withdraw_authority =
        find_withdraw_authority_program_address(program_id, stake_pool_address).0;
    let (validator_stake_address, _) =
        find_stake_program_address(program_id, &vote_account_address, stake_pool_address);
    let (transient_stake_address, _) =
        find_transient_stake_program_address(program_id, &vote_account_address, stake_pool_address);
    decrease_validator_stake(
        program_id,
        &stake_pool_address,
        &stake_pool.staker,
        &pool_withdraw_authority,
        &stake_pool.validator_list,
        &validator_stake_address,
        &transient_stake_address,
        lamports,
    )
}
/// Create a `DecreaseValidatorStake` instruction given an existing stake pool and
/// vote account
Create a `DecreaseValidatorStake` instruction given an existing stake pool and
vote account
Create a ` DecreaseValidatorStake ` instruction given an existing stake pool and vote account
pub fn decrease_validator_stake_with_vote(
    program_id: &Pubkey,
    stake_pool: &StakePool,
    stake_pool_address: &Pubkey,
    vote_account_address: &Pubkey,
    lamports: u64,
) -> Instruction {
    let pool_withdraw_authority =
        find_withdraw_authority_program_address(program_id, stake_pool_address).0;
    let (validator_stake_address, _) =
        find_stake_program_address(program_id, &vote_account_address, stake_pool_address);
    let (transient_stake_address, _) =
        find_transient_stake_program_address(program_id, &vote_account_address, stake_pool_address);
    decrease_validator_stake(
        program_id,
        &stake_pool_address,
        &stake_pool.staker,
        &pool_withdraw_authority,
        &stake_pool.validator_list,
        &validator_stake_address,
        &transient_stake_address,
        lamports,
    )
}
pub fn decrease_validator_stake_with_vote ( program_id : & Pubkey , stake_pool : & StakePool , stake_pool_address : & Pubkey , vote_account_address : & Pubkey , lamports : u64 , ) -> Instruction { let pool_withdraw_authority = find_withdraw_authority_program_address ( program_id , stake_pool_address ) . 0 ; let ( validator_stake_address , _ ) = find_stake_program_address ( program_id , & vote_account_address , stake_pool_address ) ; let ( transient_stake_address , _ ) = find_transient_stake_program_address ( program_id , & vote_account_address , stake_pool_address ) ; decrease_validator_stake ( program_id , & stake_pool_address , & stake_pool . staker , & pool_withdraw_authority , & stake_pool . validator_list , & validator_stake_address , & transient_stake_address , lamports , ) }
Create a `DecreaseValidatorStake` instruction given an existing stake pool and
vote account
Create a ` DecreaseValidatorStake ` instruction given an existing stake pool and vote account
program_id
&Pubkey
stake_pool
&StakePool
stake_pool_address
&Pubkey
vote_account_address
&Pubkey
lamports
u64
program_id
&Pubkey
stake_pool
&StakePool
stake_pool_address
&Pubkey
vote_account_address
&Pubkey
lamports
u64