toJson method

Map toJson()

Creates a json from the object

Implementation

Map toJson() {
  return {
    'name': name,
    'phone_number': phoneNumber,
    'email': email,
    'shipping_address': shippingAddress,
  }..removeWhere((_, v) => v == null);
}