The BaseGauge::setEmission
function is designed to allow the GaugeController
to modify the periodState.emission
value. However, due to the structure of the contract and its inheritance, this function is never actually invoked. This results in periodState.emission
being permanently set to its initial value from the constructor, preventing any future updates.
The BaseGauge::setEmission
function is marked with the onlyController
modifier, meaning it can only be called by the GaugeController
contract. Similarly, in RWAGauge::setMonthlyEmission
and RAACGauge::setWeeklyEmission
(which inherits BaseGauge
), are the only other functions that can modify periodState.emission
, and they are also restricted to the controller.
However, upon reviewing the GaugeController
contract, neither BaseGauge::setEmission
, RAACGauge::setWeeklyEmission
nor RWAGauge::setMonthlyEmission
are ever called. This means that once periodState.emission
is initialized in the constructor, it is never modified again.
periodState.emission
can never be updated after contract deployment.
The intended functionality of adjusting emissions dynamically is non-functional.
Manual review
Ensure that BaseGauge::setEmission
, RAACGauge::setWeeklyEmission
and RWAGauge::setMonthlyEmission
are properly called within the controller contract.
If emissions are meant to be static, consider removing these functions to avoid misleading functionality.
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.