Results.fromJson constructor Null safety
Implementation
Results.fromJson(Map<String, dynamic> json) {
category = json['category'];
type = json['type'];
difficulty = json['difficulty'];
question = json['question'];
correctAnswer = json['correct_answer'];
incorrectAnswers = json['incorrect_answers'].cast<String>();
}