fix: setState issue

This commit is contained in:
2026-05-18 22:43:53 +02:00
parent 9c5e72e6ed
commit 44c474ae77

View File

@@ -143,9 +143,9 @@ class _PlayerSelectionState extends State<PlayerSelection> {
child: TextIconTile( child: TextIconTile(
text: player.name, text: player.name,
suffixText: getNameCountText(player), suffixText: getNameCountText(player),
onIconTap: () { onIconTap: () async {
setState(() async {
await HapticFeedback.selectionClick(); await HapticFeedback.selectionClick();
setState(() {
// Removes the player from the selection and notifies the parent. // Removes the player from the selection and notifies the parent.
selectedPlayers.remove(player); selectedPlayers.remove(player);
widget.onChanged([...selectedPlayers]); widget.onChanged([...selectedPlayers]);