cardinal-stake-pool 2.2.1

Cardinal stake pool
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
use crate::errors::ErrorCode;
use crate::state::*;
use anchor_lang::prelude::*;

#[derive(Accounts)]
pub struct DeauthorizeMintCtx<'info> {
    #[account(mut)]
    stake_pool: Account<'info, StakePool>,
    #[account(mut, close = authority, constraint = stake_authorization_record.pool == stake_pool.key() @ ErrorCode::InvalidStakeAuthorizationRecord)]
    stake_authorization_record: Account<'info, StakeAuthorizationRecord>,
    #[account(mut, constraint = authority.key() == stake_pool.authority @ ErrorCode::InvalidPoolAuthority)]
    authority: Signer<'info>,
}

pub fn handler(_ctx: Context<DeauthorizeMintCtx>) -> Result<()> {
    Ok(())
}