|
1 | 1 | /** |
2 | | - * This code was AUTOGENERATED using the kinobi library. |
| 2 | + * This code was AUTOGENERATED using the codama library. |
3 | 3 | * Please DO NOT EDIT THIS FILE, instead use visitors |
4 | | - * to add features, then rerun kinobi to update it. |
| 4 | + * to add features, then rerun codama to update it. |
5 | 5 | * |
6 | | - * @see https://github.com/kinobi-so/kinobi |
| 6 | + * @see https://github.com/codama-idl/codama |
7 | 7 | */ |
8 | 8 |
|
9 | 9 | import { |
@@ -42,6 +42,16 @@ import { |
42 | 42 | } from '@solana/web3.js'; |
43 | 43 | import { MintProofV2Seeds, findMintProofV2Pda } from '../pdas'; |
44 | 44 |
|
| 45 | +export const MINT_PROOF_V2_DISCRIMINATOR = new Uint8Array([ |
| 46 | + 22, 197, 150, 178, 249, 225, 183, 75, |
| 47 | +]); |
| 48 | + |
| 49 | +export function getMintProofV2DiscriminatorBytes() { |
| 50 | + return fixEncoderSize(getBytesEncoder(), 8).encode( |
| 51 | + MINT_PROOF_V2_DISCRIMINATOR |
| 52 | + ); |
| 53 | +} |
| 54 | + |
45 | 55 | export type MintProofV2 = { |
46 | 56 | discriminator: ReadonlyUint8Array; |
47 | 57 | /** Length of proof without padding. */ |
@@ -77,10 +87,7 @@ export function getMintProofV2Encoder(): Encoder<MintProofV2Args> { |
77 | 87 | ['creationSlot', getU64Encoder()], |
78 | 88 | ['payer', getAddressEncoder()], |
79 | 89 | ]), |
80 | | - (value) => ({ |
81 | | - ...value, |
82 | | - discriminator: new Uint8Array([22, 197, 150, 178, 249, 225, 183, 75]), |
83 | | - }) |
| 90 | + (value) => ({ ...value, discriminator: MINT_PROOF_V2_DISCRIMINATOR }) |
84 | 91 | ); |
85 | 92 | } |
86 | 93 |
|
|
0 commit comments