copyWith method
Returns a copy with the given fields replaced. For a nullable
field pass a function, e.g. field: () => null to clear it.
Implementation
@override
LinkPreviewTypeVideo copyWith({
Video? video,
Photo? Function()? cover,
int? startTimestamp,
}) => LinkPreviewTypeVideo(
video: video ?? this.video,
cover: cover != null ? cover() : this.cover,
startTimestamp: startTimestamp ?? this.startTimestamp,
);