diff --git a/lib/presentation/views/active_game_view.dart b/lib/presentation/views/active_game_view.dart index 6eaee45..2153d1d 100644 --- a/lib/presentation/views/active_game_view.dart +++ b/lib/presentation/views/active_game_view.dart @@ -29,13 +29,13 @@ class _ActiveGameViewState extends State { @override Widget build(BuildContext context) { + List playerIndices = + List.generate(gameSession.players.length, (index) => index); + List sortedPlayerIndices = _getSortedPlayerIndices(playerIndices); + return ListenableBuilder( listenable: gameSession, builder: (context, _) { - List playerIndices = - List.generate(gameSession.players.length, (index) => index); - List sortedPlayerIndices = - _getSortedPlayerIndices(playerIndices); return CupertinoPageScaffold( navigationBar: CupertinoNavigationBar( middle: Text(gameSession.gameTitle),