toJson method

Map<String, dynamic> toJson()

Converts instance of Customer to json

Implementation

Map<String, dynamic> toJson() {
  final customer =  {
    "email": this.email,
    "phonenumber": this.phoneNumber ?? "",
    "name": this.name ?? ""
  };
  return Utils.removeKeysWithEmptyValues(customer);
}