Sys.fromJson constructor Null safety

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

Implementation

factory Sys.fromJson(Map<String, dynamic> json) => Sys(
      type: json["type"] ?? 0,
      id: json["id"] ?? 0,
      country: json["country"] ?? "N/A",
      sunrise: json["sunrise"] ?? 0,
      sunset: json["sunset"] ?? 0,
    );