copyWith method

Phone copyWith({
  1. String? label,
  2. String? phone,
})

Creates a copy of this Phone instance but with the given fields replaced with the new values.

Implementation

Phone copyWith({
  final String? label,
  final String? phone,
}) =>
    Phone(
      label: label ?? this.label,
      phone: phone ?? this.phone,
    );