Updated on 2026-08-14
This commit is contained in:
parent
7eae28caf0
commit
6ed28b0c0c
2 changed files with 10 additions and 2 deletions
|
|
@ -57,6 +57,10 @@ public class EthEngine extends CoinEngine {
|
|||
return 18;
|
||||
}
|
||||
|
||||
protected int getChainId() {
|
||||
return ctx.getBlockchain() == Blockchain.Ethereum ? EthTransaction.ChainEnum.Mainnet.getValue() : EthTransaction.ChainEnum.Rinkeby.getValue();
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean awaitingConfirmation() {
|
||||
return false;
|
||||
|
|
@ -391,7 +395,6 @@ public class EthEngine extends CoinEngine {
|
|||
|
||||
BigInteger gasPrice = weiFee.divide(BigInteger.valueOf(21000));
|
||||
BigInteger gasLimit = BigInteger.valueOf(21000);
|
||||
Integer chainId = ctx.getBlockchain() == Blockchain.Ethereum ? EthTransaction.ChainEnum.Mainnet.getValue() : EthTransaction.ChainEnum.Rinkeby.getValue();
|
||||
|
||||
String to = targetAddress;
|
||||
|
||||
|
|
@ -399,7 +402,7 @@ public class EthEngine extends CoinEngine {
|
|||
to = to.substring(2);
|
||||
}
|
||||
|
||||
final EthTransaction tx = EthTransaction.create(to, weiAmount, nonceValue, gasPrice, gasLimit, chainId);
|
||||
final EthTransaction tx = EthTransaction.create(to, weiAmount, nonceValue, gasPrice, gasLimit, this.getChainId());
|
||||
|
||||
return new SignTask.PaymentToSign() {
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -47,6 +47,11 @@ public class RskEngine extends EthEngine {
|
|||
return 18;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected int getChainId() {
|
||||
return EthTransaction.ChainEnum.Rootstock_mainnet.getValue();
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getBalanceCurrency() {
|
||||
return Blockchain.Rootstock.getCurrency();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue