diff options
| author | historia <[not public]> | 2026-09-18 01:50:17 -0400 |
|---|---|---|
| committer | historia <[not public]> | 2026-09-18 01:50:17 -0400 |
| commit | 87d08f0151e643951769e323995f1c5ed89ee200 (patch) | |
| tree | dc42a0b30ebb5a00dd7ba505cc4eaa44f4f308bc /internal/casino/config_validate.go | |
| parent | 32a3c59cebf2a16277e54d715a67adfdbe00b456 (diff) | |
| download | thehouseoficarus-87d08f0151e643951769e323995f1c5ed89ee200.tar.gz | |
fix: harden economy recovery, shutdown concurrency, world validation, and inventory-loss paths
Diffstat (limited to 'internal/casino/config_validate.go')
| -rw-r--r-- | internal/casino/config_validate.go | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/internal/casino/config_validate.go b/internal/casino/config_validate.go index 13229bc..8e5e7b5 100644 --- a/internal/casino/config_validate.go +++ b/internal/casino/config_validate.go @@ -68,6 +68,9 @@ func validateIdentityAndBets(id string, minBet, maxBet int) error { if minBet < 0 || maxBet < 0 { return fmt.Errorf("min_bet and max_bet must not be negative") } + if minBet > 0 && maxBet == 0 && minBet > DefaultMaxBet { + return fmt.Errorf("min_bet (%d) exceeds the default maximum bet (%d); set a larger max_bet", minBet, DefaultMaxBet) + } if maxBet > 0 && maxBet < max(1, minBet) { return fmt.Errorf("max_bet must be at least min_bet") } |
