fromJson static method
Inherited by: StorePaymentPurposeGiftedStars StorePaymentPurposePremiumGift StorePaymentPurposePremiumGiftCodes StorePaymentPurposePremiumGiveaway StorePaymentPurposePremiumSubscription StorePaymentPurposeStarGiveaway StorePaymentPurposeStars
Implementation
static StorePaymentPurposePremiumGiveaway? fromJson(
Map<String, dynamic>? json,
) {
if (json == null) {
return null;
}
return StorePaymentPurposePremiumGiveaway(
parameters: GiveawayParameters.fromJson(
tdMapFromJson(json['parameters']),
),
currency: (json['currency'] as String?) ?? '',
amount: (json['amount'] as int?) ?? 0,
);
}