c-layer / contracts

C-Layer Ethereum monorepo
MIT License
73 stars 14 forks source link

Voting contract should allow hash execution based on vote resolution. #21

Closed sirhill closed 4 years ago

sirhill commented 4 years ago

A new function execute(uint256 _proposalId) public returns (bool) should be added to the voting contract.

This function should execute the resolution hash when the vote is successful on a target contract.

In VotingCore, the storage should add an address targetContract field in the Proposal structure.

'hash' should be renamed for clarity into resolutionHash

sirhill commented 4 years ago

Implementation is covered with the following commit: https://github.com/c-layer/contracts/commit/ec3578785817b9a89614ddc8972fd83528838071