copyWith method

  1. @override
ChatEventPhotoChanged copyWith({
  1. ChatPhoto? oldPhoto()?,
  2. ChatPhoto? newPhoto()?,
})
override

Returns a copy with the given fields replaced. For a nullable field pass a function, e.g. field: () => null to clear it.

Implementation

@override
ChatEventPhotoChanged copyWith({
  ChatPhoto? Function()? oldPhoto,
  ChatPhoto? Function()? newPhoto,
}) =>
    ChatEventPhotoChanged(
      oldPhoto: oldPhoto != null ? oldPhoto() : this.oldPhoto,
      newPhoto: newPhoto != null ? newPhoto() : this.newPhoto,
    );