toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  return {
    if (firstName != null) 'firstName': firstName,
    if (lastName != null) 'lastName': lastName,
    if (email != null) 'email': email,
    if (phone != null) 'phone': phone,
  };
}