fromJson static method

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

Implementation

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

  return BusinessChatLink(
    link: (json['link'] as String?) ?? '',
    text: FormattedText.fromJson(tdMapFromJson(json['text'])),
    title: (json['title'] as String?) ?? '',
    viewCount: (json['view_count'] as int?) ?? 0,
  );
}