refactor: load/save state as ptr

This commit is contained in:
Ilia Denisov
2026-01-12 19:30:50 +02:00
parent ac60bb3020
commit 4451850f22
18 changed files with 71 additions and 57 deletions
+2 -2
View File
@@ -7,14 +7,14 @@ import (
func JoinEqualGroups(configure func(*controller.Param), race string) (err error) {
control(configure, func(c *controller.Controller) {
c.ExecuteGame(func(r controller.Repo, g game.Game) {
c.ExecuteGame(func(r controller.Repo, g *game.Game) {
err = joinEqualGroups(r, g, race)
})
})
return
}
func joinEqualGroups(r controller.Repo, g game.Game, race string) error {
func joinEqualGroups(r controller.Repo, g *game.Game, race string) error {
if err := g.JoinEqualGroups(race); err != nil {
return err
}