fromJson static method

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

Implementation

static NotificationSounds? fromJson(Map<String, dynamic>? json) {
  if (json == null) {
    return null;
  }

  return NotificationSounds(
    notificationSounds: List<NotificationSound>.from(
      tdListFromJson(json['notification_sounds'])
          .map((item) => NotificationSound.fromJson(tdMapFromJson(item)))
          .whereType<NotificationSound>(),
    ),
  );
}