The code uses a CheckpointState
struct and PowerCheckpoint
library to manage historical voting power. It tracks changes in voting power over time, allowing the retrieval of an account's voting power at a specific block.
In the veRAACToken
contract, the withdraw
function updates checkpoints but the emergencyWithdraw
function does not.
Missing the checkpoint in emergencyWithdraw
could lead to inaccurate historical voting power, improper governance calculations, and inconsistent state between normal and emergency withdrawals.
Fix the emergencyWithdraw
function by adding the checkpoint:
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.