copyWith method

  1. @override
StorePaymentPurposePremiumSubscription copyWith({
  1. bool? isRestore,
  2. bool? isUpgrade,
})
override

Copy model with modified properties.

Properties:

  • is_restore: Pass true if this is a restore of a Telegram Premium purchase; only for App Store
  • is_upgrade: Pass true if this is an upgrade from a monthly subscription to early subscription; only for App Store

Implementation

@override
StorePaymentPurposePremiumSubscription copyWith({
  bool? isRestore,
  bool? isUpgrade,
}) =>
    StorePaymentPurposePremiumSubscription(
      isRestore: isRestore ?? this.isRestore,
      isUpgrade: isUpgrade ?? this.isUpgrade,
    );