summaryrefslogtreecommitdiff
path: root/pkg
diff options
context:
space:
mode:
Diffstat (limited to 'pkg')
-rw-r--r--pkg/ui/views/play.go3
1 files changed, 1 insertions, 2 deletions
diff --git a/pkg/ui/views/play.go b/pkg/ui/views/play.go
index 796813c..89754f9 100644
--- a/pkg/ui/views/play.go
+++ b/pkg/ui/views/play.go
@@ -157,8 +157,6 @@ func (m PlayModel) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
return m, exit
}
- m.paginator.SetTotalPages(len(m.games))
-
select {
case <-start:
return m, SwitchModelCmd(NewGameModel(m.width, m.height+1, m.game, m.network))
@@ -286,6 +284,7 @@ func (m *PlayModel) handleGamesResponse(msg []database.Game) (tea.Model, tea.Cmd
m.isLoading = false
m.games = msg
m.err = nil
+ m.paginator.SetTotalPages(len(m.games))
return m, nil
}