Skip to content

Commit

Permalink
chore: fix README transaction builder example
Browse files Browse the repository at this point in the history
  • Loading branch information
blckngm committed Aug 1, 2023
1 parent 25dde25 commit 837f83d
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,10 @@ Here is an example to build a CKB transfer transaction with the help of transact
String sender = "ckt1qzda0cr08m85hc8jlnfp3zer7xulejywt49kt2rr0vthywaa50xwsq2qf8keemy2p5uu0g0gn8cd4ju23s5269qk8rg4r";
String receiver = "ckt1qzda0cr08m85hc8jlnfp3zer7xulejywt49kt2rr0vthywaa50xwsqg958atl2zdh8jn3ch8lc72nt0cf864ecqdxm9zf";
Iterator<TransactionInput> iterator = new InputIterator(sender);
TransactionWithScriptGroups txWithGroups = new CkbTransactionBuilder(iterator, Network.TESTNET)
TransactionBuilderConfiguration configuration = new TransactionBuilderConfiguration(Network.TESTNET);
configuration.setFeeRate(1000);
TransactionWithScriptGroups txWithGroups = new CkbTransactionBuilder(configuration, iterator)
.addOutput(receiver, 50100000000L)
.setFeeRate(1000)
.setChangeOutput(sender)
.build();
```
Expand Down

0 comments on commit 837f83d

Please sign in to comment.