layerx-labs/dappkit

Emit event on network parameter change

bepro-bot opened this issue · 0 comments

Abstract

NetworkV2.sol is the contract for the BEPRO network and controls Bounties, PRs, TVL and some fees.

Goal

When a network parameter change happens via the changeNetworkParameter function, an event should be emitted telling what parameter changed and what’s its new value.

Deliverable

To achieve this, change changeNetworkParameter function on contracts/bepro/NetworkV2.sol:232 to emit a new event called NetworkParamChanged with values uint256 param, uint256 newvalue, uin256 oldvalue

Add new tests under test/models/network-v2.spec.ts that account for this change, adding a new it that expects an event to be caught on the logs when a network parameter has changed.

NOTE

This bounty could be complex, since the NetworkV2.sol contract is at its size limit.