fix: team json tests
Some checks failed
Pull Request Pipeline / test (pull_request) Failing after 43s
Pull Request Pipeline / lint (pull_request) Successful in 52s

This commit is contained in:
2026-05-21 21:22:12 +02:00
parent 46134a4f5c
commit 14eb77e241
2 changed files with 24 additions and 9 deletions

View File

@@ -200,15 +200,9 @@ class DataTransferService {
.map((id) => playerById[id])
.whereType<Player>()
.toList();
final team = Team.fromJson(map);
return Team(
id: map['id'] as String,
name: map['name'] as String,
createdAt: DateTime.parse(map['createdAt'] as String),
color: AppColor.values.byName(map['color'] ?? AppColor.blue),
members: members,
score: map['score'] as int?,
);
return team.copyWith(members: members);
}).toList();
}