aboutsummaryrefslogtreecommitdiffhomepage
path: root/backend/tournament
AgeCommit message (Collapse)Author
2026-03-20fix(tournament): restrict BYE auto-win to round 0 onlynsfisis
In later rounds, a nil player means the opponent is TBD (e.g., waiting for a semifinal winner), not a BYE. Previously these were incorrectly marked as BYE wins. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-02-21refactor: rename stuttering exported types in game and tournament packagesnsfisis
Fix golangci-lint revive warnings by removing package name prefixes: - game.GameHubInterface → game.HubInterface - game.GameDetail → game.Detail - tournament.TournamentEntry → tournament.Entry - tournament.TournamentMatch → tournament.Match - tournament.TournamentBracket → tournament.Bracket - tournament.TournamentEditData → tournament.EditData Also fix gofmt alignment in api/convert.go and gosimple S1016 in game/service.go. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-21refactor(admin): separate business logic into game and tournament servicesnsfisis
Move transaction handling, rejudge workflow, tournament bracket creation, and data repair logic from admin handler into game.Service and tournament.Service, mirroring the earlier api package separation. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-21refactor(api): separate business logic into game, tournament, session packagesnsfisis
Extract business logic from api/handler.go into dedicated service packages: - session: context helpers (resolves admin → api import dependency) - game: game state, code submission, ranking, watch logic - tournament: bracket construction and seed ordering - api/convert.go: domain → API type conversion functions api/handler.go is now a thin adapter that delegates to services and maps domain errors to HTTP status codes. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>