You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// Note: Poseidon's transpiler does not support initializeMint yet,
63
+
// so this code is done manually using Anchor's InitializeMint.
64
+
// init,
65
+
// payer = mint_authority,
66
+
// mint::decimals = decimals,
67
+
// mint::authority = mint_authority.key(), this code is added manually
35
68
#[account(
36
69
init,
37
70
payer = mint_authority,
38
71
mint::decimals = decimals,
39
72
mint::authority = mint_authority.key(),
40
73
)]
41
74
pubmint_account:Account<'info,Mint>,
75
+
// Token Program and System Program is added manually as Poseidon does not support it yet using initializeMint
42
76
pubtoken_program:Program<'info,Token>,
43
77
pubsystem_program:Program<'info,System>,
44
78
}
45
79
#[derive(Accounts)]
46
80
pubstructMintContext<'info>{
47
-
#[account(mut)]
81
+
#[account(mut)]// here (mut) is added manually as Poseidon didn't add it by its own causing error in build
48
82
pubmint_account:Account<'info,Mint>,
49
83
#[account(mut)]
50
84
pubmint_authority:Signer<'info>,
51
85
#[account(mut)]
52
86
pubrecipient:SystemAccount<'info>,
53
87
#[account(
54
88
init_if_needed,
55
-
payer = mint_authority,
89
+
payer = mint_authority,// Explicitly set payer to mint_authority due to Poseidon issue. Here poseidon added payer as mintAuthority but it should be mint_authority
0 commit comments