TokenInstruction.thawAccount constructor
TokenInstruction.thawAccount({
- required Ed25519HDPublicKey account,
- required Ed25519HDPublicKey mint,
- required Ed25519HDPublicKey freezeAuthority,
- List<
Ed25519HDPublicKey> signers = const <Ed25519HDPublicKey>[],
Thaw a Frozen account using the mint's freezeAuthority.
Implementation
factory TokenInstruction.thawAccount({
required Ed25519HDPublicKey account,
required Ed25519HDPublicKey mint,
required Ed25519HDPublicKey freezeAuthority,
List<Ed25519HDPublicKey> signers = const <Ed25519HDPublicKey>[],
}) =>
TokenInstruction._(
accounts: [
AccountMeta.writeable(pubKey: account, isSigner: false),
AccountMeta.writeable(pubKey: mint, isSigner: false),
AccountMeta.writeable(
pubKey: freezeAuthority,
isSigner: signers.isEmpty,
),
...signers.map(
(pubKey) => AccountMeta.readonly(pubKey: pubKey, isSigner: true),
),
],
data: TokenProgram.thawAccountInstructionIndex,
);