PayloadListResponse.fromJson constructor

PayloadListResponse.fromJson(
  1. dynamic json
)

Implementation

PayloadListResponse.fromJson(dynamic json) {
  payloads = [];
  error = null;
  if (json == null) {
    error = "json is null";
  } else {
    List pushMessages = json['pushMessages'] as List;
    payloads = pushMessages.map(Payload.fromJson).toList();
  }
}