copyWith method

  1. @override
UpdateChatAccentColors copyWith({
  1. int? chatId,
  2. int? accentColorId,
  3. int? backgroundCustomEmojiId,
  4. UpgradedGiftColors? upgradedGiftColors()?,
  5. int? profileAccentColorId,
  6. int? profileBackgroundCustomEmojiId,
  7. dynamic extra,
  8. int? clientId,
})
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
UpdateChatAccentColors copyWith({
  int? chatId,
  int? accentColorId,
  int? backgroundCustomEmojiId,
  UpgradedGiftColors? Function()? upgradedGiftColors,
  int? profileAccentColorId,
  int? profileBackgroundCustomEmojiId,
  dynamic extra,
  int? clientId,
}) => UpdateChatAccentColors(
  chatId: chatId ?? this.chatId,
  accentColorId: accentColorId ?? this.accentColorId,
  backgroundCustomEmojiId:
      backgroundCustomEmojiId ?? this.backgroundCustomEmojiId,
  upgradedGiftColors: upgradedGiftColors != null
      ? upgradedGiftColors()
      : this.upgradedGiftColors,
  profileAccentColorId: profileAccentColorId ?? this.profileAccentColorId,
  profileBackgroundCustomEmojiId:
      profileBackgroundCustomEmojiId ?? this.profileBackgroundCustomEmojiId,
  extra: extra ?? this.extra,
  clientId: clientId ?? this.clientId,
);