fromJsonToMessageList function Null safety

List<Message> fromJsonToMessageList(
  1. List json
)

Implementation

List<Message> fromJsonToMessageList(List<dynamic> json) =>
    json.map((e) => Message.fromJson(e as Map<String, dynamic>)).toList();