copyWith method

AcceptedGiftTypes copyWith({
  1. bool? unlimitedGifts,
  2. bool? limitedGifts,
  3. bool? upgradedGifts,
  4. bool? giftsFromChannels,
  5. bool? premiumSubscription,
})

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

Implementation

AcceptedGiftTypes copyWith({
  bool? unlimitedGifts,
  bool? limitedGifts,
  bool? upgradedGifts,
  bool? giftsFromChannels,
  bool? premiumSubscription,
}) => AcceptedGiftTypes(
  unlimitedGifts: unlimitedGifts ?? this.unlimitedGifts,
  limitedGifts: limitedGifts ?? this.limitedGifts,
  upgradedGifts: upgradedGifts ?? this.upgradedGifts,
  giftsFromChannels: giftsFromChannels ?? this.giftsFromChannels,
  premiumSubscription: premiumSubscription ?? this.premiumSubscription,
);