commit 6b5aa8c48c1910a10986f9bd7db30665328f91d1
parent 724256344e21ab937d2f466aeef3938ff0758057
Author: n0tr1v <n0tr1v@protonmail.com>
Date: Mon, 18 Dec 2023 23:07:04 -0500
cleanup
Diffstat:
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/pkg/web/handlers/poker/poker.go b/pkg/web/handlers/poker/poker.go
@@ -331,7 +331,7 @@ func (g *Ongoing) getPlayerBySeatIdx(seatIdx int) (*PokerPlayer, int) {
return nil, -1
}
-func (g *Ongoing) CountCanVotePlayers() (nbCanVote int) {
+func (g *Ongoing) countCanBetPlayers() (nbCanVote int) {
for _, p := range g.Players {
if !p.Folded.Load() && !p.isAllIn() {
nbCanVote++
@@ -795,8 +795,8 @@ func execBettingRound(g *PokerGame, skip int, minBet database.PokerChip) bool {
playerAlive := ongoing.CountAlivePlayers()
// Avoid asking for actions if only 1 player can do so (because others are all-in)
- nbCanVote := ongoing.CountCanVotePlayers()
- if nbCanVote == 0 || nbCanVote == 1 {
+ nbCanBet := ongoing.countCanBetPlayers()
+ if nbCanBet == 0 || nbCanBet == 1 {
goto RoundIsSettled
}