-
Notifications
You must be signed in to change notification settings - Fork 383
Open
Labels
Description
- I have updated Purchases SDK to the latest version
- I have read the Contribution Guidelines
- I have searched the Community
- I have read docs.revenuecat.com
- I have searched for existing Github issues
-
Environment
- Platform: iOS
- SDK version: main branch
- StoreKit version:
- StoreKit 1 (default on versions <5.0.0. Can be enabled in versions >=5.0.0 with
.with(storeKitVersion: .storeKit1)
) - StoreKit 2 (default on versions >=5.0.0)
- StoreKit 1 (default on versions <5.0.0. Can be enabled in versions >=5.0.0 with
- OS version: n/a
- Xcode version: n/a
- Device and/or simulator:
- Device
- [] Simulator (not an issue because the sandbox value is respected)
- Environment:
- Sandbox
- TestFlight
- Production
- How widespread: I believe the problem would affect any customers who have purchased a production non-subscription SKU and then for whatever reason purchased the same SKU again in TestFlight.
-
Ask if really needed but I don't think you'll need them.
-
Steps to reproduce, with a description of expected vs. actual behavior
- Arrange for a customer to have two purchases of the same non-subscription item. One, in production, should be dated earlier than one in sandbox.
- In code, request the latest customer info.
- Examine the
CustomerInfoResponse.Subscriber.allPurchasesByID
and see that the only non-subscription purchase represented in the list is from the sandbox.
-
In this scenario, the
entitlements.activeInCurrentEnvironment
value ends up not listing the entitlement corresponding to the production purchase, presumably because it was stripped in the process of building the entitlements array.