@marinade.finance/kamino-sdk
Version:
20 lines • 1.04 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.closeProgramAccount = void 0;
const web3_js_1 = require("@solana/web3.js"); // eslint-disable-line @typescript-eslint/no-unused-vars
const programId_1 = require("../programId");
function closeProgramAccount(accounts) {
const keys = [
{ pubkey: accounts.adminAuthority, isSigner: true, isWritable: true },
{ pubkey: accounts.program, isSigner: false, isWritable: false },
{ pubkey: accounts.programData, isSigner: false, isWritable: false },
{ pubkey: accounts.closingAccount, isSigner: false, isWritable: true },
{ pubkey: accounts.systemProgram, isSigner: false, isWritable: false },
];
const identifier = Buffer.from([245, 14, 192, 211, 99, 42, 170, 187]);
const data = identifier;
const ix = new web3_js_1.TransactionInstruction({ keys, programId: programId_1.PROGRAM_ID, data });
return ix;
}
exports.closeProgramAccount = closeProgramAccount;
//# sourceMappingURL=closeProgramAccount.js.map