@lightprotocol/compressed-token 0.17.0 → 0.17.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/browser/index.cjs +10 -3
- package/dist/cjs/browser/index.cjs.map +1 -1
- package/dist/cjs/node/index.cjs +10 -3
- package/dist/cjs/node/index.cjs.map +1 -1
- package/dist/es/browser/index.js +10 -3
- package/dist/es/browser/index.js.map +1 -1
- package/dist/types/index.d.ts +4 -1
- package/package.json +2 -2
|
@@ -2017,7 +2017,10 @@ class CompressedTokenProgram {
|
|
|
2017
2017
|
return address;
|
|
2018
2018
|
}
|
|
2019
2019
|
/**
|
|
2020
|
-
* Construct createMint instruction for compressed tokens
|
|
2020
|
+
* Construct createMint instruction for compressed tokens.
|
|
2021
|
+
* @returns [createMintAccountInstruction, initializeMintInstruction, createTokenPoolInstruction]
|
|
2022
|
+
*
|
|
2023
|
+
* Note that `createTokenPoolInstruction` must be executed after `initializeMintInstruction`.
|
|
2021
2024
|
*/
|
|
2022
2025
|
static async createMint(params) {
|
|
2023
2026
|
const { mint, authority, feePayer, rentExemptBalance, tokenProgramId, freezeAuthority, mintSize, } = params;
|
|
@@ -2031,12 +2034,16 @@ class CompressedTokenProgram {
|
|
|
2031
2034
|
space: mintSize !== null && mintSize !== void 0 ? mintSize : splToken.MINT_SIZE,
|
|
2032
2035
|
});
|
|
2033
2036
|
const initializeMintInstruction = splToken.createInitializeMint2Instruction(mint, params.decimals, authority, freezeAuthority, tokenProgram);
|
|
2034
|
-
const
|
|
2037
|
+
const createTokenPoolInstruction = await this.createTokenPool({
|
|
2035
2038
|
feePayer,
|
|
2036
2039
|
mint,
|
|
2037
2040
|
tokenProgramId: tokenProgram,
|
|
2038
2041
|
});
|
|
2039
|
-
return [
|
|
2042
|
+
return [
|
|
2043
|
+
createMintAccountInstruction,
|
|
2044
|
+
initializeMintInstruction,
|
|
2045
|
+
createTokenPoolInstruction,
|
|
2046
|
+
];
|
|
2040
2047
|
}
|
|
2041
2048
|
/**
|
|
2042
2049
|
* Enable compression for an existing SPL mint, creating an omnibus account.
|