listFromJson static method

Implementation

static List<PersonPatchPreferencesNotification> listFromJson(
    List<dynamic>? json) {
  if (json == null) {
    return <PersonPatchPreferencesNotification>[];
  }

  return json.fold(<PersonPatchPreferencesNotification>[],
      (List<PersonPatchPreferencesNotification> previousValue, element) {
    final PersonPatchPreferencesNotification? object =
        PersonPatchPreferencesNotification.fromJson(element);
    if (object is PersonPatchPreferencesNotification) {
      previousValue.add(object);
    }

    return previousValue;
  });
}