fromJson static method

GameHighScores? fromJson(
  1. Map<String, dynamic>? json
)

Implementation

static GameHighScores? fromJson(Map<String, dynamic>? json) {
  if (json == null) {
    return null;
  }

  return GameHighScores(
    scores: List<GameHighScore>.from(
      tdListFromJson(json['scores'])
          .map((item) => GameHighScore.fromJson(tdMapFromJson(item)))
          .whereType<GameHighScore>(),
    ),
  );
}