Skip to content

Commit

Permalink
Use lamports() in deserialize transaction example (#2984)
Browse files Browse the repository at this point in the history
Lest we lead anyone astray that this is denominated in SOL or that numbers are preferable over bigints.
  • Loading branch information
steveluscher authored Jul 25, 2024
1 parent 1ae2a80 commit 2d2709e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion examples/deserialize-transaction/src/example.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ import {
getBase64Encoder,
getCompiledTransactionMessageDecoder,
getTransactionDecoder,
lamports,
partiallySignTransactionMessageWithSigners,
pipe,
setTransactionMessageFeePayer,
Expand Down Expand Up @@ -107,7 +108,7 @@ const transactionMessage = pipe(
appendTransactionMessageInstructions(
[
getTransferSolInstruction({
amount: 12345678,
amount: lamports(12345678n),
destination: DESTINATION_ADDRESS,
source: SOURCE_ACCOUNT_SIGNER,
}),
Expand Down

0 comments on commit 2d2709e

Please sign in to comment.