File tree Expand file tree Collapse file tree 10 files changed +400
-340
lines changed Expand file tree Collapse file tree 10 files changed +400
-340
lines changed Original file line number Diff line number Diff line change 4242 },
4343 "homepage" : " https://github.com/solana-program/memo#readme" ,
4444 "peerDependencies" : {
45- "@solana/kit" : " ^3 .0"
45+ "@solana/kit" : " ^4 .0"
4646 },
4747 "devDependencies" : {
4848 "@ava/typescript" : " ^4.1.0" ,
4949 "@solana/eslint-config-solana" : " ^3.0.3" ,
50- "@solana/kit" : " ^3 .0" ,
50+ "@solana/kit" : " ^4 .0" ,
5151 "@types/node" : " ^24" ,
5252 "@typescript-eslint/eslint-plugin" : " ^7.16.1" ,
5353 "@typescript-eslint/parser" : " ^7.16.1" ,
Original file line number Diff line number Diff line change 11/**
2- * This code was AUTOGENERATED using the codama library.
2+ * This code was AUTOGENERATED using the Codama library.
33 * Please DO NOT EDIT THIS FILE, instead use visitors
4- * to add features, then rerun codama to update it.
4+ * to add features, then rerun Codama to update it.
55 *
66 * @see https://github.com/codama-idl/codama
77 */
Original file line number Diff line number Diff line change 11/**
2- * This code was AUTOGENERATED using the codama library.
2+ * This code was AUTOGENERATED using the Codama library.
33 * Please DO NOT EDIT THIS FILE, instead use visitors
4- * to add features, then rerun codama to update it.
4+ * to add features, then rerun Codama to update it.
55 *
66 * @see https://github.com/codama-idl/codama
77 */
@@ -81,23 +81,18 @@ export function getAddMemoInstruction<
8181 } )
8282 ) ;
8383
84- const instruction = {
84+ return Object . freeze ( {
8585 accounts : remainingAccounts ,
86- programAddress,
8786 data : getAddMemoInstructionDataEncoder ( ) . encode (
8887 args as AddMemoInstructionDataArgs
8988 ) ,
90- } as AddMemoInstruction < TProgramAddress > ;
91-
92- return instruction ;
89+ programAddress,
90+ } as AddMemoInstruction < TProgramAddress > ) ;
9391}
9492
9593export type ParsedAddMemoInstruction <
9694 TProgram extends string = typeof MEMO_PROGRAM_ADDRESS ,
97- > = {
98- programAddress : Address < TProgram > ;
99- data : AddMemoInstructionData ;
100- } ;
95+ > = { programAddress : Address < TProgram > ; data : AddMemoInstructionData } ;
10196
10297export function parseAddMemoInstruction < TProgram extends string > (
10398 instruction : Instruction < TProgram > & InstructionWithData < ReadonlyUint8Array >
Original file line number Diff line number Diff line change 11/**
2- * This code was AUTOGENERATED using the codama library.
2+ * This code was AUTOGENERATED using the Codama library.
33 * Please DO NOT EDIT THIS FILE, instead use visitors
4- * to add features, then rerun codama to update it.
4+ * to add features, then rerun Codama to update it.
55 *
66 * @see https://github.com/codama-idl/codama
77 */
Original file line number Diff line number Diff line change 11/**
2- * This code was AUTOGENERATED using the codama library.
2+ * This code was AUTOGENERATED using the Codama library.
33 * Please DO NOT EDIT THIS FILE, instead use visitors
4- * to add features, then rerun codama to update it.
4+ * to add features, then rerun Codama to update it.
55 *
66 * @see https://github.com/codama-idl/codama
77 */
Original file line number Diff line number Diff line change 11/**
2- * This code was AUTOGENERATED using the codama library.
2+ * This code was AUTOGENERATED using the Codama library.
33 * Please DO NOT EDIT THIS FILE, instead use visitors
4- * to add features, then rerun codama to update it.
4+ * to add features, then rerun Codama to update it.
55 *
66 * @see https://github.com/codama-idl/codama
77 */
Original file line number Diff line number Diff line change 11/**
2- * This code was AUTOGENERATED using the codama library.
2+ * This code was AUTOGENERATED using the Codama library.
33 * Please DO NOT EDIT THIS FILE, instead use visitors
4- * to add features, then rerun codama to update it.
4+ * to add features, then rerun Codama to update it.
55 *
66 * @see https://github.com/codama-idl/codama
77 */
@@ -23,7 +23,7 @@ import {
2323 * @internal
2424 */
2525export function expectSome < T > ( value : T | null | undefined ) : T {
26- if ( value == null ) {
26+ if ( value === null || value === undefined ) {
2727 throw new Error ( 'Expected a value but received null or undefined.' ) ;
2828 }
2929 return value ;
@@ -48,7 +48,7 @@ export function expectAddress<T extends string = string>(
4848 return value . address ;
4949 }
5050 if ( Array . isArray ( value ) ) {
51- return value [ 0 ] ;
51+ return value [ 0 ] as Address < T > ;
5252 }
5353 return value as Address < T > ;
5454}
Original file line number Diff line number Diff line change 44 "generate:clients" : " zx ./scripts/generate-clients.mjs"
55 },
66 "devDependencies" : {
7- "@codama/renderers-js" : " ^1.3 " ,
7+ "@codama/renderers-js" : " ^1.4 " ,
88 "@codama/renderers-rust" : " ~1.1" ,
99 "@iarna/toml" : " ^2.2.5" ,
1010 "codama" : " ^1.3" ,
You can’t perform that action at this time.
0 commit comments