The FertilizerFacet.claimFertilized()
calls the IFertilizer
interface on its beanstalkUpdate()
function in amount
calculation.
However, the Fertilizer
contract does not declare is IFertilizer
in its definition.
The claimFertilized()
calls IFertilizer.beanstalkUpdate()
in uint256 amount = C.fertilizer().beanstalkUpdate(msg.sender, ids, s.bpf);
:
Here is C.fertilizer()
that invokes IFertilizer
interface:
and here is C.fertilizer.beanstalkUpdate()
:
However, Fertilizer
contract does not declare is IFertilizer
in its definition:
Though it has the beanstalkUpdate()
implementation:
Even if the Fertilizer
contract has a beanStalkUpdate()
function that matches the signature in the IFertilizer
interface, not using is IFertilizer
means the contract is not formally considered an implementation of that interface, which affects enforceability & type compatibility.
The result will cause FertilizerFacet.claimFertilized()
to fail forever as there is no implementation of the IFertilizer.beanstalkUpdate()
resulting in failure to Rinse Rinsable Sprouts earned from Fertilizer
.
Manual Review
The Fertilizer
contract needs to declare that it implements the IFertilizer
interface through is IFertilizer
.
This setup ensures that any contract or external caller interacting with the Fertilizer
contract through the IFertilizer
interface can call the beanStalkUpdate()
function, relying on the concrete implementation provided within the Fertilizer
contract.
The LiquidityWeightFacet
contract also needs to declare is ILiquidityWeightFacet
so that any other contract that tries to invoke the maxWeight()
function through the interface can do so since the implementation exists.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.