Instruction name swap
* Instruction -> GenericInstruction * Instruction<u8, u8> -> CompiledInstruction * Instruction<Pubkey, (Pubkey, bool)> -> Instruction
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
use crate::id;
|
||||
use serde_derive::{Deserialize, Serialize};
|
||||
use solana_sdk::pubkey::Pubkey;
|
||||
use solana_sdk::transaction_builder::BuilderInstruction;
|
||||
use solana_sdk::transaction::Instruction;
|
||||
|
||||
#[derive(Serialize, Deserialize, Debug, PartialEq, Eq, Clone)]
|
||||
pub enum RewardsInstruction {
|
||||
@@ -9,8 +9,8 @@ pub enum RewardsInstruction {
|
||||
}
|
||||
|
||||
impl RewardsInstruction {
|
||||
pub fn new_redeem_vote_credits(vote_id: &Pubkey, rewards_id: &Pubkey) -> BuilderInstruction {
|
||||
BuilderInstruction::new(
|
||||
pub fn new_redeem_vote_credits(vote_id: &Pubkey, rewards_id: &Pubkey) -> Instruction {
|
||||
Instruction::new(
|
||||
id(),
|
||||
&RewardsInstruction::RedeemVoteCredits,
|
||||
vec![(*vote_id, true), (*rewards_id, false)],
|
||||
|
||||
Reference in New Issue
Block a user