From 7d1ee0bcaf35c702cbf1589ceb11e2308a984084 Mon Sep 17 00:00:00 2001 From: Kamo Spertsyan Date: Tue, 24 Dec 2024 16:23:41 +0300 Subject: [PATCH 1/3] Fixed update policy for purchase with options. --- lib/src/internal/qonversion_internal.dart | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/src/internal/qonversion_internal.dart b/lib/src/internal/qonversion_internal.dart index 3c8e75a..d213ff9 100644 --- a/lib/src/internal/qonversion_internal.dart +++ b/lib/src/internal/qonversion_internal.dart @@ -112,13 +112,16 @@ class QonversionInternal implements Qonversion { promoOfferData['timestamp'] = purchaseOptions.promotionalOffer?.paymentDiscount.timestamp; } + final updatePolicy = purchaseOptions.updatePolicy; final rawResult = await _channel .invokeMethod(Constants.mPurchase, { Constants.kProductId: product.qonversionId, Constants.kOldProductId: purchaseOptions.oldProduct?.qonversionId, Constants.kOfferId: purchaseOptions.offerId, Constants.kApplyOffer: purchaseOptions.applyOffer, - Constants.kUpdatePolicyKey: purchaseOptions.updatePolicy, + Constants.kUpdatePolicyKey: updatePolicy != null + ? StringUtils.capitalize(describeEnum(updatePolicy)) + : null, Constants.kPurchaseContextKeys: purchaseOptions.contextKeys, Constants.kPurchaseQuantity: purchaseOptions.quantity, Constants.kPromoOffer: promoOfferData, From 4187a4ad26cdee68f77970227d19ce9de3ee103d Mon Sep 17 00:00:00 2001 From: SpertsyanKM Date: Tue, 24 Dec 2024 13:34:25 +0000 Subject: [PATCH 2/3] [create-pull-request] automated change --- CHANGELOG.md | 3 +++ lib/src/internal/qonversion_internal.dart | 2 +- pubspec.yaml | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1497296..485bbd4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,6 @@ +## 9.2.1 +* // Update changelog here + ## 9.2.0 * iOS promotional offers supported. For the details see the [documentation](https://documentation.qonversion.io/docs/apple-promotional-offers). * Minimal supported Dart SDK version is bumped to 2.14.0. diff --git a/lib/src/internal/qonversion_internal.dart b/lib/src/internal/qonversion_internal.dart index d213ff9..dd2f93f 100644 --- a/lib/src/internal/qonversion_internal.dart +++ b/lib/src/internal/qonversion_internal.dart @@ -11,7 +11,7 @@ import 'package:qonversion_flutter/src/internal/utils/string.dart'; import 'constants.dart'; class QonversionInternal implements Qonversion { - static const String _sdkVersion = "9.2.0"; + static const String _sdkVersion = "9.2.1"; final MethodChannel _channel = MethodChannel('qonversion_plugin'); diff --git a/pubspec.yaml b/pubspec.yaml index 638b8c8..c7c6d73 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: qonversion_flutter description: Flutter plugin to implement in-app subscriptions and purchases. Validate user receipts and manage cross-platform access to paid content on your app. Android & iOS. -version: 9.2.0 +version: 9.2.1 homepage: 'https://qonversion.io' repository: 'https://github.com/qonversion/flutter-sdk' From 7e084cb7b6843c4c5a7ddc6c767c53c6026ee895 Mon Sep 17 00:00:00 2001 From: Kamo Spertsyan Date: Tue, 24 Dec 2024 16:35:35 +0300 Subject: [PATCH 3/3] Update CHANGELOG.md --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 485bbd4..1f0857b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,5 @@ ## 9.2.1 -* // Update changelog here +* Fixed update policy issue for purchase with options. ## 9.2.0 * iOS promotional offers supported. For the details see the [documentation](https://documentation.qonversion.io/docs/apple-promotional-offers).