copyWith method

  1. @override
CartItemModel copyWith({
  1. String? documentID,
  2. int? amount,
  3. String? appId,
  4. ProductModel? product,
})
override

Implementation

@override
CartItemModel copyWith({
  String? documentID,
  int? amount,
  String? appId,
  ProductModel? product,
}) {
  return CartItemModel(
    documentID: documentID ?? this.documentID,
    amount: amount ?? this.amount,
    appId: appId ?? this.appId,
    product: product ?? this.product,
  );
}