Sorry, I am not familiar with the sushiswap, is there a failed transaction hash?
Maybe you can ask help from swshiswap team, and they have some test cases in their contract repo, maybe you can have a look at them.
No, no failed transaction, nothing.
But I noticed when I use add() function to the pool and then I type poolInfo.length it returns 0, when it should return 1 I guess.
Do you know what the second parameter should take on add() function?
function add(
uint256 _allocPoint,
IERC20 _lpToken,
bool _withUpdate
)
There is a modifier for this function onlyOwner, so did you use the owner account to call this function?
As for _lpToken, for example, if you add liquidity of Your_Token-ETH into the sushiswap, you will get some LP tokens, so the token address you got is the value _lpToken
Hey, thank you.
I think you are putting me on the right course.
So, this must be a flow - First, I create pair from the interface, then when I add liquidity and I receive LP tokens I must pass that address as the second argument on add() function. But how can I get the address of the LP token I receive? which solidity file shall I use?
P.S I was told that _lpToken is the pair address of two tokens, guess it’s wrong.
I think it should be the masterchief, I am not sure, and maybe you can have a look at the scripts which would deploy contracts or the test case in the sushiswap repo.
Hey, yes contract is MasterChief, but when I call Add() function, and after I run poolInfo.length it returns 0, I guess it should return 1 if add() function worked.