Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: simple quorum comment and var name #246

Merged
merged 1 commit into from
Dec 7, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/execution-strategies/SimpleQuorumExecutionStrategy.sol
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ abstract contract SimpleQuorumExecutionStrategy is IExecutionStrategy, SpaceMana

/// @notice Returns the status of a proposal that uses a simple quorum.
/// A proposal is accepted if the for votes exceeds the against votes
/// and a quorum of total votes (for + against + abstain) is reached.
/// and a quorum of (for + abstain) votes is reached.
/// @param proposal The proposal struct.
/// @param votesFor The number of votes for the proposal.
/// @param votesAgainst The number of votes against the proposal.
Expand Down Expand Up @@ -68,8 +68,8 @@ abstract contract SimpleQuorumExecutionStrategy is IExecutionStrategy, SpaceMana
}

function _quorumReached(uint256 _quorum, uint256 _votesFor, uint256 _votesAbstain) internal pure returns (bool) {
uint256 totalVotes = _votesFor + _votesAbstain;
return totalVotes >= _quorum;
uint256 forAndAbstainVotesTotal = _votesFor + _votesAbstain;
return forAndAbstainVotesTotal >= _quorum;
}

function _supported(uint256 _votesFor, uint256 _votesAgainst) internal pure returns (bool) {
Expand Down
Loading