nonceAdvance static method
Generates an instruction to advance the nonce in a Nonce account.
Keys:
[w]
noncePubkey
The nonce account.[s]
authorizedPubkey
The public key of the nonce authority.
Implementation
static TransactionInstruction nonceAdvance({
required final Pubkey noncePubkey,
required final Pubkey authorizedPubkey,
}) {
final List<AccountMeta> keys = [
AccountMeta.writable(noncePubkey),
AccountMeta(sysvarRecentBlockhashesPubkey),
AccountMeta.signer(authorizedPubkey),
];
return _instance.createTransactionIntruction(
SystemInstruction.advanceNonceAccount,
keys: keys,
);
}