The FeeConversionKeeper is a keeper used for automatic fee distribution. It works with two main functions - checkUpkeep and performUpkeep. When checkUpkeep returns true, performUpkeep executes. Inside checkUpkeep there is a call to checkFeeDistributionNeeded to decide whether a distribution is needed or not. However, the function does not work as intended because it makes a call to FeeDistributionBranch::getAssetValue and expects the value do be in base 18. The function returns "the calculated value of the asset in its native units".
The FeeConversionKeeper is a keeper used for automatic fee distribution. It works with two main functions - checkUpkeep and performUpkeep. When checkUpkeep returns true, performUpkeep executes. Inside checkUpkeep there is a call to checkFeeDistributionNeeded to decide whether a distribution is needed or not. However, the function does not work as intended because it makes a call to FeeDistributionBranch::getAssetValue and expects the value do be in base 18. The function returns "the calculated value of the asset in its native units".
And
As we can see the minFeeDistributionValueUsd is a fixed value. However, different assets have different collaterals which have different decimals. This means that the current logic will work only for assets with collaterals with decimals equal to 18. If they are less than the assetValue will never be enough to trigger a distribution.
Non working FeeConversionKeeper which means non converted fees to WETH in the cases in which the decimals of the collateral of a given asset is less than 18.
Manual Review
Either make a call to collateral.convertTokenAmountToUd60x18 for the returned value of getAssetValue or add a new function (for example getAssetValueX18) that will do this internally and return the value in base 18.
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.