UserData.fromJson constructor

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

Implementation

UserData.fromJson(Map<String, dynamic> json)
  : super(
      availabilityText: json['availabilityText'],
      custom: (json['custom'] != null ? Map.from(json['custom']) : null),
      email: (json['email'] != null
          ? (json['email'] is String
                ? [json['email']]
                : List.from(json['email']))
          : null),
      phone: (json['phone'] != null
          ? (json['phone'] is String
                ? [json['phone']]
                : List.from(json['phone']))
          : null),
      id: json['id'],
      name: json['name'],
      locale: json['locale'],
      photoUrl: json['photoUrl'],
      role: json['role'],
      welcomeMessage: json['welcomeMessage'],
    );