This repository has been archived by the owner on Jan 10, 2025. It is now read-only.
Token JS: Use COptionPubkeyLayout
for all COption
fields
#6170
Labels
After #6164, we now have a serialization layout for
COption<Pubkey>
, where aNone
value is represented by a single0
, whileSome(Pubkey)
is represented by a1
plus the public key bytes.There are a handful more instructions in Token2022 that use
COption<Pubkey>
. Here are a few examples:solana-program-library/token/program-2022/src/instruction.rs
Lines 474 to 482 in 8b22d75
solana-program-library/token/program-2022/src/instruction.rs
Lines 549 to 553 in 8b22d75
Update their JavaScript instruction builders to use the new layout!
The text was updated successfully, but these errors were encountered: