fromJson static method
Inherited by: ChatAvailableReactionsAll ChatAvailableReactionsSome
Implementation
static ChatAvailableReactionsSome? fromJson(Map<String, dynamic>? json) {
if (json == null) {
return null;
}
return ChatAvailableReactionsSome(
reactions: List<ReactionType>.from(
tdListFromJson(json['reactions'])
.map((item) => ReactionType.fromJson(tdMapFromJson(item)))
.whereType<ReactionType>(),
),
maxReactionCount: (json['max_reaction_count'] as int?) ?? 0,
);
}