From 53ad7ed03d4d06a3e8eeed500348e113a7761459 Mon Sep 17 00:00:00 2001 From: Brian Wiborg Date: Mon, 13 May 2024 12:12:43 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Fix=20missing=20unanimous=20quor?= =?UTF-8?q?um/threshold?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- voting/quorum/quorum.go | 5 ++--- voting/threshold/threshold.go | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/voting/quorum/quorum.go b/voting/quorum/quorum.go index 729594d..c0acb08 100644 --- a/voting/quorum/quorum.go +++ b/voting/quorum/quorum.go @@ -23,7 +23,7 @@ const ( func ValidQuorums() []Quorum { return []Quorum{ - Simple, + Simple, Unanimous, OneFifth, OneQuarter, OneThird, OneHalf, TwoThirds, TwoFifths, ThreeQuarters, ThreeFifths, @@ -97,7 +97,6 @@ func (q Quorum) IsSatisfied(possibleVotes, totalVotes int) bool { case Unanimous: return totalVotes >= possibleVotes default: - panic("this code should never be reached⚜️") + panic("this code should never be reached") } - return false } diff --git a/voting/threshold/threshold.go b/voting/threshold/threshold.go index fdee948..2f21e68 100644 --- a/voting/threshold/threshold.go +++ b/voting/threshold/threshold.go @@ -23,7 +23,7 @@ const ( func ValidThresholds() []Threshold { return []Threshold{ - Simple, + Simple, Unanimous, OneFifth, OneQuarter, OneThird, OneHalf, TwoFifths, TwoThirds, ThreeFifths, ThreeQuarters, ThreeFifths,