Skip to content

Commit

Permalink
Fix audit #GAS-02
Browse files Browse the repository at this point in the history
Fix logic
  • Loading branch information
cwsnt committed Jan 14, 2022
1 parent 0989ce5 commit 0f512f3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion contracts/governance/GovernorAlpha.sol
Expand Up @@ -531,7 +531,7 @@ contract GovernorAlpha is SafeMath96 {
uint96 totalVotesMajorityPercentage =
mul96(totalVotes, majorityPercentageVotes, "GovernorAlpha:: state: totalVotes * majorityPercentage > uint96");
totalVotesMajorityPercentage = div96(totalVotesMajorityPercentage, 100, "GovernorAlpha:: state: division error");
if (proposal.forVotes <= totalVotesMajorityPercentage || totalVotes < proposal.quorum) {
if (proposal.forVotes < totalVotesMajorityPercentage || totalVotes < proposal.quorum) {
return ProposalState.Defeated;
}
Expand Down

0 comments on commit 0f512f3

Please sign in to comment.