Skip to content

浏览器钱包调用 split coin #25

Answered by v1xingyue
v1xingyue asked this question in Q&A
Discussion options

You must be logged in to vote

很神奇 灵异的错误。

需要把这句

 const [coins] = tx.splitCoins(tx.gas,[tx.pure(10000)]);

改成

const coins = tx.splitCoins(tx.gas,[tx.pure(10000)]); 

同时,注意 split-coin 会把当前的 coin 拆分成一个对应的coin,另外的gas 会 自动merge 。

Replies: 1 comment

Comment options

v1xingyue
May 30, 2023
Maintainer Author

You must be logged in to vote
0 replies
Answer selected by v1xingyue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant