The updateDAOMembership function in the MembershipFactory contract lacks event emission for critical state changes. This function modifies core DAO configurations including tier structures and maximum member limits without emitting any events to track these modifications. This omission significantly impacts the contract's transparency and makes it difficult for off-chain services to track and react to DAO configuration changes.
Location: MembershipFactory.sol - updateDAOMembership function (L144-178)
The function modifies several critical state variables:
Updates the tier configurations array (dao.tiers)
Modifies the maximum member limit (dao.maxMembers)
Updates the number of tiers (dao.noOfTiers)
However, no events are emitted to track these changes, unlike other state-changing functions in the contract such as createNewDAOMembership which emits the MembershipDAONFTCreated event.
Contrast with the proper event emission in createNewDAOMembership:
Transparency Loss:
Off-chain services cannot track DAO configuration changes
Difficulty in maintaining UI synchronization with contract state
Operational Challenges:
DAO members have no way to receive notifications about tier structure changes
Historical tracking of DAO evolution becomes impossible
Potential synchronization issues between front-end applications and contract state
Integration Issues:
Third-party integrations cannot react to DAO updates
Indexing services miss critical state changes
Analytics platforms receive incomplete data
Manual code review
Add an event emission at the end of the updateDAOMembership function:
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.