ChatList.fromJson constructor

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

Parses whichever ChatList subtype the JSON describes.

Implementation

factory ChatList.fromJson(Map<String, dynamic> json) {
  final object = tdObjectFactories[json['@type']]?.call(json);
  return object is ChatList ? object : UndecodedChatList(json);
}