New answers tagged

0

I also got the same error. However, I updated the Node version(v14.17.0) and it's not throwing 'fs-promise' error. So please update your Node version.


1

I always prefer to prevent require statements in view methods, unless it's really necessary. Because sometimes, backends like Metamask, due to some limitation, don't include the revert reason strings in the error, which causes user interfaces to have a hard time figuring out the cause of the error. I'd instead suggest you to change your method to: function ...


1

this is the code snippet from the frontend of Pancakeswap, and if I not wrong MasterChef calculates in the same way. /** * Get the APR value in % * @param stakingTokenPrice Token price in the same quote currency * @param rewardTokenPrice Token price in the same quote currency * @param totalStaked Total amount of stakingToken in the pool * @param ...


0

Your contract has no function named set(). Your contract has a function named setname() instead. (The same holds true for get() -> getname().)


Top 50 recent answers are included