Hi
For some reason I am getting the following error:
Warning! Error encountered during contract execution [ execution reverted ]
Link: TX
Do I need to pass gasPrice or what I am missing?
Inputs over form are. (1BNB) 1000000000000000000 (250 Custom token) 25000000000000000000
const token2 = new ethers.Contract(
this.state.tokenBData.address,
ERC20.abi,
this.state.signer
);
const tx = await token2.approve(
this.state.router.connect(this.state.signer).address,
tokenBAmount,
{
from: this.state.account,
...this.overrides,
}
);
await tx.wait(1);
const tx2 = await this.state.router
.connect(this.state.signer)
.addLiquidityETH(
this.state.tokenBData.address,
tokenBAmount, //TokenB
tokenBAmount,
tokenAAmount,
this.state.account,
deadline,
{
from: this.state.account,
value: tokenAAmount, //ETH
...this.overrides,
}
);
await tx2.wait(1);