Compound Contracts
Relationship between Governance and TimelockGovernance is the admin of Timelock and Timelock is also the admin of Governance. It looks tricky, but actually reasonable. The fact is only Governance have the right to use Timelock to execute a proposal. And when Governance need to change the parameters for itself, the only reasonable way would be a proposal via Timelock.cTokenmarket contract for a type of Token, like USDT, DAI etc
Compound Contracts
Relationship between Governance and TimelockGovernance is the admin of Timelock and Timelock is also the admin of Governance. It looks tricky, but actually reasonable. The fact is only Governance have the right to use Timelock to execute a proposal. And when Governance need to change the parameters for itself, the only reasonable way would be a proposal via Timelock.cTokenmarket contract for a type of Token, like USDT, DAI etc
Mining Contract
https://github.com/sushiswap/sushiswap/blob/canary/contracts/MasterChef.solSystem FunctionsAdd: add new LP token for Mining. Set: set reward allocPoint, which can be used to calculate reward per block for specific pool. massUpdatePools: Update all accSushiPerShare for all pools updatePool: Mainly used to update single accSushiPerShare for specific pool, also mint sushi for a period.Deposita. updatePool b. calculate pending reward = user current LP number * accSushiPerShare - debt c. transfer ...
Mining Contract
https://github.com/sushiswap/sushiswap/blob/canary/contracts/MasterChef.solSystem FunctionsAdd: add new LP token for Mining. Set: set reward allocPoint, which can be used to calculate reward per block for specific pool. massUpdatePools: Update all accSushiPerShare for all pools updatePool: Mainly used to update single accSushiPerShare for specific pool, also mint sushi for a period.Deposita. updatePool b. calculate pending reward = user current LP number * accSushiPerShare - debt c. transfer ...