|
@@ -156,6 +156,11 @@ class PaymentQueueController: NSObject, SKPaymentTransactionObserver {
|
|
}
|
|
}
|
|
|
|
|
|
func onEntitlementRevocation(_ revocation: EntitlementRevocation) {
|
|
func onEntitlementRevocation(_ revocation: EntitlementRevocation) {
|
|
|
|
+ guard entitlementRevocation == nil else {
|
|
|
|
+ print("SwiftyStoreKit.onEntitlementRevocation() should only be called once when the app launches. Ignoring this call")
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+
|
|
self.entitlementRevocation = revocation
|
|
self.entitlementRevocation = revocation
|
|
}
|
|
}
|
|
|
|
|
|
@@ -248,10 +253,6 @@ class PaymentQueueController: NSObject, SKPaymentTransactionObserver {
|
|
}
|
|
}
|
|
|
|
|
|
func paymentQueue(_ queue: SKPaymentQueue, didRevokeEntitlementsForProductIdentifiers productIdentifiers: [String]) {
|
|
func paymentQueue(_ queue: SKPaymentQueue, didRevokeEntitlementsForProductIdentifiers productIdentifiers: [String]) {
|
|
- guard entitlementRevocation == nil else {
|
|
|
|
- print("SwiftyStoreKit.onEntitlementRevocation() should only be called once when the app launches. Ignoring this call")
|
|
|
|
- return
|
|
|
|
- }
|
|
|
|
|
|
|
|
self.entitlementRevocation?.callback(productIdentifiers)
|
|
self.entitlementRevocation?.callback(productIdentifiers)
|
|
}
|
|
}
|