FirebaseChatDocument.fromJson constructor
Constructs a FirebaseChatDocument from JSON.
Implementation
FirebaseChatDocument.fromJson(Map<String, dynamic> json, this.id)
: title = json['title'],
imageUrl = json['image_url'],
personal = json['personal'],
canBeDeleted = json['can_be_deleted'] ?? true,
lastUsed = json['last_used'],
users = json['users'] != null ? List<String>.from(json['users']) : [],
lastMessage = json['last_message'] == null
? null
: FirebaseMessageDocument.fromJson(
json['last_message'],
null,
);