From eacafe11615b243db1e3d167620f4a2d5d70472f Mon Sep 17 00:00:00 2001 From: Michael Vines Date: Wed, 27 Jul 2022 14:29:01 -0600 Subject: [PATCH] Simplify handling when stake_redelegate_instruction is not yet active --- programs/stake/src/stake_instruction.rs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/programs/stake/src/stake_instruction.rs b/programs/stake/src/stake_instruction.rs index 0a37e34998b7ad..c7f86951fc6669 100644 --- a/programs/stake/src/stake_instruction.rs +++ b/programs/stake/src/stake_instruction.rs @@ -426,6 +426,7 @@ pub fn process_instruction( } } Ok(StakeInstruction::Redelegate) => { + let mut me = get_stake_account()?; if invoke_context .feature_set .is_active(&feature_set::stake_redelegate_instruction::id()) @@ -452,11 +453,6 @@ pub fn process_instruction( &signers, ) } else { - if !invoke_context.feature_set.is_active( - &feature_set::add_get_minimum_delegation_instruction_to_stake_program::id(), - ) { - let _ = get_stake_account()?; - } Err(InstructionError::InvalidInstructionData) } }