Profile.fromJson constructor
Creates a Profile instance from a JSON map.
Implementation
factory Profile.fromJson(Map<String, dynamic> json) => Profile(
email: json["email"],
image: json["image"],
isAdminBlocked: Platform.isAndroid
? json["isAdminBlocked"]
: json["isBlockedByAdmin"],
isBlocked: json["isBlocked"],
isBlockedMe: json["isBlockedMe"],
isGroupAdmin: json["isGroupAdmin"],
isGroupInOfflineMode: json["isGroupInOfflineMode"],
isGroupProfile: Platform.isAndroid
? json["isGroupProfile"]
: json["profileChatType"].toString().toLowerCase() == "singlechat"
? false
: true,
isItSavedContact: json["isItSavedContact"],
isMuted: json["isMuted"],
isSelected: json["isSelected"],
jid: json["jid"],
mobileNumber: json["mobileNumber"],
name: json["name"],
nickName: json["nickName"],
status: json["status"],
thumbImage: json["thumbImage"],
);